Can't install SMB V2 on NSA325v2
Hello everyone,
i tried to update samba on my Zyxel NSA325v2 according to this HOW TO https://zyxel.diskstation.eu/forum/viewtopic.php?t=24&sid=3e40a8ef0b230af1ad6c9d0802170f46
It fails at the Point where i start /opt/etc/init.d/S09ZyXELSambaReplacement.
An error accured: mw: can`t rename '/opt/var/lock/*': No such file or directory
Can anyone help me?
Best Regards
All Replies
-
That is caused by next lines in the start script:
# Move /opt/var/lock to ramdrive, else the maintenance of browse.dat will keep the disk awake
if [ ! -h /opt/var/lock ]
then
mv /opt/var/lock/* /var/lock/
rmdir /opt/var/lock && ln -s /var/lock /opt/var/lock
fiApparently you don't have an /opt/var/lock directory, so you can just create the symlink
ln -s /var/lock /opt/var/lock
0 -
Thank you for the quick answer.
Unfortunetly after i did the command
ln -s /var/lock /opt/var/lock
and then tried to start
/opt/etc/init.d/S09ZyXELSambaReplacement start
nothing happens.
What can i do?
0 -
Try restart instead of start. Or reboot the box.
0 -
Tried both. Nothing happens.
Anything else i can do?
0 -
Use the 'debug mode' of the startscript:
/bin/sh -x /opt/etc/init.d/S09ZyXELSambaReplacement start
0 -
Is this good or bad?
I tried to check smbstatus but it throws an error.
0 -
~ # /bin/sh -x /opt/etc/init.d/S09ZyXELSambaReplacement start
- prgmname1=/opt/sbin/nmbd
- prgmname2=/opt/sbin/smbd
- configfile=/opt/etc/samba/ZyXELSambaReplacement.conf
- nmbdpid=/opt/var/run/nmbd-ZyXELSambaReplacement.conf.pid
- smbdpid=/opt/var/run/smbd-ZyXELSambaReplacement.conf.pid
- basename /opt/etc/init.d/S09ZyXELSambaReplacement
- [ S09ZyXELSambaReplacement = samba.sh ]
- startreplacement
- [ -f /etc/init.d/samba.replaced.sh ]
- return
- exit
this is the output.
0 -
[ -f /etc/init.d/samba.replaced.sh ]
return
Are you sure that it isn't automatically started on boot? The start procedure is roughly
- Stop stock firmware (/etc/init.d/samba.sh stop)
- Rename firmware startscript to /etc/init.d/samba.replaced.sh
- Create a symlink /etc/init.d/samba.sh to /opt/etc/init.d/S09ZyXELSambaReplacement
- Start the Entware samba via this symlink (/etc/init.d/samba.sh start)
The symlink is created because the firmware uses it to restart samba when needed. This way the firmware restarts the Entware samba without knowing (or needing to know)
Stopping of the replacement is the same sequence reversed.
The script checks if the renamed startscript is available, and if so, then exits, which seems to be the case.
0
Categories
- All Categories
- 415 Beta Program
- 2.4K Nebula
- 151 Nebula Ideas
- 98 Nebula Status and Incidents
- 5.7K Security
- 277 USG FLEX H Series
- 277 Security Ideas
- 1.4K Switch
- 74 Switch Ideas
- 1.1K Wireless
- 42 Wireless Ideas
- 6.4K Consumer Product
- 250 Service & License
- 395 News and Release
- 85 Security Advisories
- 29 Education Center
- 10 [Campaign] Zyxel Network Detective
- 3.6K FAQ
- 34 Documents
- 34 Nebula Monthly Express
- 85 About Community
- 75 Security Highlight