Displaying 2 results from an estimated 2 matches for "samba2ramf".
Did you mean:
samba2ram
2016 Feb 04
3
A question about Samba logging
Hi
May I ask for help with this again please?
I’m trying to ensure that Samba writes its wins.dat file to tmpfs.
I have added these mount commands to /etc/init.d/samba:
case $1 in
start)
mount -t tmpfs tmpfs /var/run/samba
mount -t tmpfs tmpfs /var/cache/samba
/etc/init.d/nmbd start
/etc/init.d/smbd start
2016 Feb 05
0
A question about Samba logging
...reate the samba2ram.service folder to add this service file.
/etc/systemd/system/samba2ram.service
chmod 664 /etc/systemd/system/samba2ram.service
add something like this to the service file.
[Unit]
Description=Samba tmpfs copy/restore to ramdisk
[Service]
Type=oneshot
ExecStart=/usr/local/sbin/samba2ramfs.sh
ExecStop=/usr/local/sbin/samba2ramfs.sh
Before=samba.service
RemainAfterExit=yes
[Install]
WantedBy=multiuser.target
Example very simple copy script.
/usr/local/sbin/samba2ramfs.sh
#!/bin/bash
if [ "${1}" = "start" ]; then
cp -R /var/cache/samba /run/samba/varcache
c...