Kismet: Saving the Kismet Database to a Samba Share

Date: 8 September 2020

Table of Contents

Introduction

For a while, I attempted to set up Kismet (running in a VM) in a way that would enable it to save the database (which is just sqllite) to a mounted Samba share. However, Kismet would just refuse to start and only provided cryptic error messages. After enough debugging, I found a solution that will allow it to work. Essentially, the trick is to the nobrl option for mount.cifs, which disables Byte-Range Locking. I'm not sure what secondary consequences this may have on Kismet, so proceed with mild caution.

Samba Mount Configuration

Edit your fstab file as follows:

	sudo vim /etc/fstab
	
Add your mount entry at the bottom:
	//192.168.1.xxx/SHARE /path/to/mount_point cifs username=USER,password=PASSWORD,workgroup=WORKGROUP,noauto,x-systemd.automount,x-systemd.idle-timeout=30,rw,nobrl 0 0
	
Obviously, change the above line to match your configuration. Once the fstab file is edited, then reload the sytemd daemon:
	systemctl daemon-reload 
	systemctl restart remote-fs.target 
	
This should cause systemd to mount the share at /path/to/mount_point. Now, simply tell Kismet to use that path as the location to store the database.

Kismet Configuration

Edit the kismet logging configuraiton file:

	sudo vim /usr/local/etc/kismet_logging.conf
	
Edit the log_prefix line:
	log_prefix=/path/to/mount_point
	
Now just restart Kismet
	sudo service kismet restart
	
And that's it!

Conclusion

Kismet should load and run without complaints.