Zyxel Forum - Herzlich Willkommen!

Aktuelle Zeit: Do 24. Okt 2019, 01:23

Alle Zeiten sind UTC + 1 Stunde




Ein neues Thema erstellen Auf das Thema antworten  [ 13 Beiträge ]  Gehe zu Seite 1, 2  Nächste
Autor Nachricht
BeitragVerfasst: Sa 12. Jan 2019, 10:11 
Offline

Registriert: Mi 14. Nov 2018, 19:50
Beiträge: 52
The samba version on ZyXEL fw4 boxes is old, and supports only the smb1 protocol. Windows 10 by default doesn't support smb1 anymore, so there's a problem.

Fortunately samba is more or less separated from the rest of the firmware, so it's possible to replace it. Entware-ng provides a samba server 3,6,25 for Armv5, which is new enough to support smb2.

I wrote a small package zyxel-samba-replacement, which injects Entware-ng samba into the firmware.

How it works
The firmware samba is started and stopped using the /etc/init.d/samba.sh script. Samba is configured to use /etc/samba/smb.conf as configuration file. When you change some samba settings in the webinterface, smb.conf is updated, and a signal is send to the running samba daemon to reload the configuration.

The zyxel-samba-replacement stops firmware samba by executing '/etc/init.d/samba.sh stop', and then exchanges the script by a symlink to /opt/etc/init.d/S09ZyXELSambaReplacement, and starts Entware-ng samba.
This samba uses /opt/etc/samba/ZyXELSambaReplacement.conf as configuration. This file enables smb2, and then includes /etc/samba/smb.conf. This way the firmware can change configuration without touching our smb2 setting.

How to install
Code:
su
opkg update
opkg install zyxel-samba-replacement     # will automatically pull the samba server

# disable the Entware-ng samba server and script
/opt/etc/init.d/S08samba stop
chmod a-x /opt/etc/init.d/S08samba

# enable and start the replacement script
chmod a+x /opt/etc/init.d/S09ZyXELSambaReplacement
/opt/etc/init.d/S09ZyXELSambaReplacement start

That's it. It can be confusing that by executing '/opt/etc/init.d/S09ZyXELSambaReplacement start' you see samba stopping, and with '/opt/etc/init.d/S09ZyXELSambaReplacement stop' you see it starting. That's the firmware samba. The replacement script always stops one, and starts the other.

Known issues
The recycle bin doesn't work. So disable it on all shares before installing the replacement.


Nach oben
 Profil  
 
BeitragVerfasst: Fr 1. Feb 2019, 10:04 
Offline

Registriert: Sa 26. Jan 2019, 08:57
Beiträge: 3
Hi Mijzelf,

Thank you a lot for your overall contribution to Zyxel NAS community in general and for this package particular.

I use NSA325v2 and recently was ought to upgrade my PC to Win10, accordingly I decided to upgrade samba on my NSA. I've installed zyxel-samba-replacement package successfully and the only minor issue I have is the NSA is not visible in network browser on Win10. Same way on smb1 devices like media player and smart TV NSA is not visible as well.
But by the entrance of IP address to either address string in Win10 explorer or link in media player and smart TV NSA is accessible and I'm able to map drive in Win10 and read files from NSA on player and TV.
Please comment if this is a normal behaviour.


Nach oben
 Profil  
 
BeitragVerfasst: So 3. Feb 2019, 14:44 
Offline

Registriert: Mi 14. Nov 2018, 19:50
Beiträge: 52
Kostya_Ye hat geschrieben:
Please comment if this is a normal behaviour.

Actually I don't know, but it wouldn't surprise me. I don't own any Windows PC's, and borrowed a W10 laptop to test the Samba implementation. It worked, and so did it on my Linux box. I never looked if the nas/share was visible in the network browser. Just haven't thought of it. On the nas-central forum people reported that the Recycle bin didn't work, another thing I didn't test. Maybe someone also mentioned that network browsing doesn't work, but I can't remember, and unfortunately the forum is down.

It wouldn't surprise me if that is normal behaviour because the way it was implemented in smb1 (or actually, in netbios), doesn't scale up very well, and is hard to route. Basically it's dependent on broadcasts, and if you have a lot of Windows machines, that can become a serious network load.
So it isn't surprising if MS dumped that for something more efficient. But the truth is that I don't know how it works now. Maybe the Entware samba package doesn't support it. Maybe it needs some extra configuration in /opt/etc/samba/ZyXELSambaReplacement.conf.


Nach oben
 Profil  
 
BeitragVerfasst: Di 5. Feb 2019, 17:39 
Offline

Registriert: Sa 26. Jan 2019, 08:57
Beiträge: 3
Hi Mijzelf,
OK, clear.
as i wrote such samba behavior is not a big problem for me so just will keep as it goes.


Nach oben
 Profil  
 
BeitragVerfasst: So 10. Mär 2019, 12:32 
Offline

Registriert: So 10. Mär 2019, 12:13
Beiträge: 4
Hello,

Mijzelf hat geschrieben:
How to install


i read this three times but i don't understand who i can put the changes on my NSA310.
Must i use a linux-pc und a ssh connection to my NAS or can i replace the settings via webinterface ?
And where is the file "zyxel-samba-replacement" ?

I'm a german Win10-User and i need your help.
I will only update samba and not the complete Firmware.
I will not lose any files on my NAS.

Greetings from germany
Heiko


Nach oben
 Profil  
 
BeitragVerfasst: So 10. Mär 2019, 14:35 
Offline

Registriert: Mi 14. Nov 2018, 19:50
Beiträge: 52
This thread is posted in the Entware-ng subforum, and the install instructions presume that you have installed and are using Entware-ng. So install that first (instructions here), and come back if zyxel-samba-replacement still puzzles your.


Nach oben
 Profil  
 
BeitragVerfasst: Sa 21. Sep 2019, 12:08 
Offline

Registriert: Sa 21. Sep 2019, 11:14
Beiträge: 4
Hi!

I want to update SMB on my NSA325 V2 (FW4.81) to a higher version to get it work with WIN10 again and to get rid of security issues caused by SMB1.

So I was very happy about this thread, but unfortunatey I am not able to make it work! :-( I spent now days and it doesnt work, so I would really appreciate your help.

Steps done so far:

1) Activated MetaRepository (20181001zypkg015), so I was able to install Entware_ng in the package view of web ui
2) Installed Entware_ng in the package view of web ui (20181002zypkg006) - Note: SSH is installed, FFP is not installed
3) Started SSH with root login
4) Tried to execute the commands as stated in "How to install" section
5) opkg update - returns: command not found!
6) the same when I am entering the complete path to opkg or moving to the targer directory and entering opkg update

After I was stuck here, I also tried the sceanrio with creating an FAT USB Stick and booting the NSA with it (USB port1 on backside) - but this was also not successful, as the NSA boots, but the in SSH the commands still not working.

There must be something I am doing wrong - can anybody help? Please

Many thanks in advance.


Zuletzt geändert von mes am Sa 21. Sep 2019, 19:44, insgesamt 3-mal geändert.

Nach oben
 Profil  
 
BeitragVerfasst: Sa 21. Sep 2019, 17:18 
Offline
Benutzeravatar

Registriert: Sa 10. Nov 2018, 17:36
Beiträge: 37
Du kannst auch versuchen, SMB1.0 unter Windows 10 zu aktivieren.
https://mein-dms.agorum.com/blog/so-akt ... windows-10

Ich hatte auf einem älteren PC das Problem, dass es damit trotzdem nicht ging. Ich musste dann Windows 10 auf diesem PC neu installieren.


Nach oben
 Profil  
 
BeitragVerfasst: Sa 21. Sep 2019, 19:38 
Offline

Registriert: Sa 21. Sep 2019, 11:14
Beiträge: 4
@shv: Danke für den Tipp! Das ist allerdings keine Alternative - ich hätte das Sicherheitsrisiko SMB1 gerne ausgeräumt.

@Mijzelf: Any idea?


Nach oben
 Profil  
 
BeitragVerfasst: So 22. Sep 2019, 14:27 
Offline

Registriert: Mi 14. Nov 2018, 19:50
Beiträge: 52
mes hat geschrieben:
@Mijzelf: Any idea?

Not directly. It should have worked. In the webinterface you should be able to find the log of the initial install. Can you post that?


Nach oben
 Profil  
 
Beiträge der letzten Zeit anzeigen:  Sortiere nach  
Ein neues Thema erstellen Auf das Thema antworten  [ 13 Beiträge ]  Gehe zu Seite 1, 2  Nächste

Alle Zeiten sind UTC + 1 Stunde


Wer ist online?

Mitglieder in diesem Forum: 0 Mitglieder und 1 Gast


Du darfst keine neuen Themen in diesem Forum erstellen.
Du darfst keine Antworten zu Themen in diesem Forum erstellen.
Du darfst deine Beiträge in diesem Forum nicht ändern.
Du darfst deine Beiträge in diesem Forum nicht löschen.
Du darfst keine Dateianhänge in diesem Forum erstellen.

Suche nach:
Gehe zu:  
cron
Powered by phpBB® Forum Software © phpBB Group
Deutsche Übersetzung durch phpBB.de