New Build - 06-01-2020-r43320

Post new topic   Reply to topic    DD-WRT Forum Index -> Broadcom SoC based Hardware
Goto page Previous  1, 2
Author Message
rnix
DD-WRT User


Joined: 23 Feb 2016
Posts: 200

PostPosted: Tue Jun 02, 2020 22:03    Post subject: Reply with quote
mwchang wrote:

Confirming this!

Reverting back to 43290 did NOT fix the problem until AFTER a cold boot! It seemed something in the memory related to NAS was not cleared after a soft reboot.

Note: I had both MiniDLNA and Samba using the same music folder. So the problem might not be Samba.

Update:

It's MiniDLNA! Accessing Samba shares in build 43320 no longer rebooted after I disabled it.

I suspected it's just the temporary/cache files of MiniDLNA...



I don't think it's MiniDLNA as I had it always disabled and reboots still occurred.
Sponsor
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1857
Location: Hung Hom, Hong Kong

PostPosted: Wed Jun 03, 2020 11:55    Post subject: Reply with quote
rnix wrote:
mwchang wrote:

It's MiniDLNA! Accessing Samba shares in build 43320 no longer rebooted after I disabled it.

I suspected it's just the temporary/cache files of MiniDLNA...


I don't think it's MiniDLNA as I had it always disabled and reboots still occurred.

Weird.... it did fix my reboot problem. And my Samba shares are on a ext4 partitions.

Are you using Transmission BT client and/or ProFTPd? For my RT-N18U, I only enabled Samba Server in the NAS tab.

Update:
I had since re-enabled MiniDLNA, and there was no reboot issue. I guess my MiniDLNA had rebuilt its metadata/cache files.

Update 2:
Well, it rebooted again. Disabling MiniDLNA and see! Smile

Update 3:
It still rebooted if I accessed Samba shares after some idle period of not using Samba. Reverting back to build 43290 to see if the problem stayed. Mr. rnix, maybe you were correct after all. Smile

Update 4:
It's Samba(ksmbd), not MiniDLNA! Possibly memory leaks...


_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw


Last edited by mwchang on Sat Jun 06, 2020 13:17; edited 1 time in total
moisesmcardona
DD-WRT Novice


Joined: 22 Jun 2014
Posts: 44

PostPosted: Fri Jun 05, 2020 13:43    Post subject: Reply with quote
Router/Version: Linksys EA6500 v1
File: dd-wrt-43320-ea6500.trx
Firmware: DD-WRT v3.0-r43320 giga (06/01/20)
Kernel: Linux 4.4.225 #1546 Mon Jun 1 12:52:30 +04 2020 mips
Mode: Router
Reset?: N
Status: Working

_________________
Linksys WRT32X, Linksys EA6500 v1, TP-Link TL-WR842ND
Spectrum 940/35 mbit
tony_p
DD-WRT Novice


Joined: 03 Jun 2020
Posts: 4

PostPosted: Sat Jun 06, 2020 0:41    Post subject: Confirming samba reboot issue Reply with quote
Router/Version: Netgear R7000
File/Kernel: Linux DD-WRT 4.4.225 #289 SMP Sun May 31 07:53:20 +04 2020 armv7l
Previous: Stock Netgear R7000_V1.0.4.18_1.1.52
Reset: Not at first, but then yes (before and after flash)
Mode/Status: Gateway / AP / NAS
Issues/Errors:

Confirming Samba reboot bug.

First time user, installed over stock Netgear firmware 1.0.4.18_1.1.52 after doing a factory reset from Netgear gui. Installed DDWRT 43320, did another factory reset from gui. Running fine as I found my way around the firmware. I used fdisk, mke2fs and mkswap through ssh to create and format ext2/swap partitions (#1 512M Opt, #2 64M swap, #3 6.4G Data) for Entware. Mounted fine, installed Entware + Transmission (DDWRT built in Transmission disabled). Ran Transmission fine, created shared folder and user fine. Access shared folder through Samba via Windows 10 machine immediately rebooted the router and partitions on usb disk were deleted (fdisk /dev/sda after reboot revealed no partitions).

Performed erase nvram, reflashed #43320, reset password to access gui, performed another erase nvram, did not use backup file. Repeated steps as above except accessed shared folder through mobile phone file manager, immediate reboot, usb partitions and data preserved.

I noted 2 ksmbd.mountd instances running but only one shared folder was setup.

1563 root ksmbd.mountd -c /tmp/smb.conf -u /tmp/smb.db
1564 root ksmbd.mountd -c /tmp/smb.conf -u /tmp/smb.db

The 2 instances are both referencing the same smb.db database simultaneously. Perhaps this is an issue, perhaps not.

After this, I then changed the router name in setup > basic setup > optional settings > router name and it's not being reflected (yet) without a reboot.

ps reveals

sh -c echo hard > /sys/class/ksmbd-control/kill_server

constantly running (hung?), and top showing high cpu usage.

2409 2 root RW 0 0.0 1 49.7 [ksmbd:40352]

A google search for "echo hard > /sys/class/ksmbd-control/kill_server" shows https://github.com/namjaejeon/ksmbd-tools/blob/master/README

RESTART KSMBD
_____________________

steps:
- kill user space daemon
killall ksmbd.mountd
- kill kernel space daemon
echo hard > /sys/class/ksmbd-control/kill_server
- restart user space daemon
ksmbd.mountd

It appears to be hanging on kill_server perhaps.

Also, this is my first time using this firmware, and reporting here on the forums. Please let me know if I'm being too verbose (sometimes I try and help a little too much).

Thanks, Tony.
mwchang
DD-WRT Guru


Joined: 26 Mar 2013
Posts: 1857
Location: Hung Hom, Hong Kong

PostPosted: Sun Jun 07, 2020 7:24    Post subject: Re: Confirming samba reboot issue Reply with quote
tony_p wrote:
Confirming Samba reboot bug.
.... more ....
I noted 2 ksmbd.mountd instances running but only one shared folder was setup.

1563 root ksmbd.mountd -c /tmp/smb.conf -u /tmp/smb.db
1564 root ksmbd.mountd -c /tmp/smb.conf -u /tmp/smb.db

The 2 instances are both referencing the same smb.db database simultaneously. Perhaps this is an issue, perhaps not.

After this, I then changed the router name in setup > basic setup > optional settings > router name and it's not being reflected (yet) without a reboot.

ps reveals

sh -c echo hard > /sys/class/ksmbd-control/kill_server

constantly running (hung?), and top showing high cpu usage.

2409 2 root RW 0 0.0 1 49.7 [ksmbd:40352]

A google search for "echo hard > /sys/class/ksmbd-control/kill_server" shows https://github.com/namjaejeon/ksmbd-tools/blob/master/README

RESTART KSMBD
_____________________

steps:
- kill user space daemon
killall ksmbd.mountd
- kill kernel space daemon
echo hard > /sys/class/ksmbd-control/kill_server
- restart user space daemon
ksmbd.mountd

It appears to be hanging on kill_server perhaps.

Thank you for sharing! Maybe your findings should be filed to Samba-related SVN logs....

I believe Samba was never part of DD-WRT's kernel, but just a user-land tool. So all these methods to start/stop Samba via WEBUI failed because it's no longer a user-land process.


_________________
Router: Asus RT-N18U (rev. A1)

Drink, Blink, Stretch! Live long and prosper! May the Force and farces be with you!

Facebook: https://www.facebook.com/changmanwai
Website: https://sites.google.com/site/changmw
SETI@Home profile: http://setiathome.berkeley.edu/view_profile.php?userid=211832
GitHub: https://github.com/changmw/changmw
Goto page Previous  1, 2 Display posts from previous:    Page 2 of 2
Post new topic   Reply to topic    DD-WRT Forum Index -> Broadcom SoC based Hardware All times are GMT

Navigation

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You can attach files in this forum
You can download files in this forum