Bricked NS v2 after setting miniDLNA to run automatically?

Bricked NS v2 after setting miniDLNA to run automatically?

Postby jpjpjp » Wed Feb 08, 2023 10:52 pm

I've got an old Lacie NS2 that has been happily running FVDW for a long time. I haven't really touched the configuration in years, but today logged into the web GUI to enable miniDLNA. I got it set up, and it seemed to be working just fine, so I went back into the web interface and hit the button to automatically run it after a reboot. Shortly after, I rebooted the NAS through the web interface and....it never came back. I'll confess that I did ssh into it and eyeballed the changes in /etc/init.d/rc.setup and /etc/init.d/rc.bootup3 before the restart, but I'm fairly certain I didn't change anything.

I'm curious if anyone can recommend any troubleshooting steps, as I can't figure out how to reach the device.
- I *think* I was running version 16.
- I know that my NAS has had the same LAN IP address for as long as I've had it, but I can't remember if I'd set this up on the NAS (there are no static IP routing rules on my router).
- It does not respond to pings at the expected IP address (nor can I load the web admin or ssh into it).
- I've watched the DCHP Clients page in my router's Web Admin when I've rebooted the NAS, and I don't see any new clients connecting. (Unfortunately, I never made a note of the MAC address, and the design on this is "too elegant" to support a sticker or something that says what it is). Without knowing the MAC I can't conclusively say that the NAS hasn't successfully gotten a different IP address.
- Thinking that perhaps it has a different IP address now, I entered all the unnamed IP addresses that I DO see in my DHCP web console into a browser in case the NAS got a different IP address, but none of them responded.
- The device seems to be OK. It makes the normal disk spinning noises when restarted and eventually settles to a solid blue light as it always has.

As of now, I can't think of any way to contact this device, so I'm turning to the forum for help. Any advice would be greatly appreciated!
jpjpjp
Donator VIP
Donator VIP
 
Posts: 23
Joined: Wed Jan 28, 2015 12:48 am

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby Jocko » Thu Feb 09, 2023 1:36 pm

Hi

Several points must be checked :
- I *think* I was running version 16.
I do not think that because if I understand well you used the web console. This feature is available from version 16.1. So you should have at least this version.
You detect what IP is used.
So from the web console, do
Code: Select all
cat /boot.log
You should read the wanted information at the end
Jocko
Site Admin - expert
 
Posts: 11367
Joined: Tue Apr 12, 2011 4:48 pm
Location: Orleans, France

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby jpjpjp » Thu Feb 09, 2023 4:30 pm

Thank you so much for the reply!

In order to run the command you are suggesting I need to either login to the NAS or access it via the web interface, correct? Or are you suggesting the console tool described here: viewtopic.php?f=7&t=1271?

The problem I'm having is that I don't know what the IP address of the NAS is. I can't browse to the web interface (or even ping) the expected IP and none of the others that I see in my router seem to be it. Is it possible that I screwed something up so bad that it's not even getting far enough into the boot cycle to attach to the network?

FWIW I did download the console tool described here: viewtopic.php?f=7&t=1271 and tried running the fvdw-sl port scanner but it did not find anything.
jpjpjp
Donator VIP
Donator VIP
 
Posts: 23
Joined: Wed Jan 28, 2015 12:48 am

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby Jocko » Fri Feb 10, 2023 3:32 pm

Hi

Sorry, I misunderstood you : I tough you still have a ssh access via the web-console
I'll confess that I did ssh into it and eyeballed the changes in /etc/init.d/rc.setup and /etc/init.d/rc.bootup3 before the restart, but I'm fairly certain I didn't change anything.
And yes, open these files may be enough to corrupt them if you used a bad file editor like wordpad (which changes the breakline charcode)

So with no access, you have to use fvdw-sl console.
So read these topics : https://plugout.net/viewtopic.php?f=7&t=3086
https://plugout.net/viewtopic.php?f=7&t=2645

You have to use the action "Standalone kernel, load and start" which allows you to get a telnet access. On a nwps2, you have to select this kernel image : UIMAGE-3142-KIRKWOOD-171-standalone

After connecting to please to post these outputs
Code: Select all
mkdir sda7
mount /dev/sda7 sda7
cat /sda7/boot.log
This allows you to detect what firmware partition is used sda1 or sda2. Then do (sdax is either sda1 or sda2)
Code: Select all
mk sdax
mount /dev/sdax sdax
cat /sdax/boot.log
with this last output we will be able to detect at what step there is an issue
Jocko
Site Admin - expert
 
Posts: 11367
Joined: Tue Apr 12, 2011 4:48 pm
Location: Orleans, France

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby jpjpjp » Fri Feb 10, 2023 9:07 pm

Thanks Jocko.

I tried to do the "standalone kernel, load and start" in the fvdw-sl console, but telnet isn't working.

As I mentioned, I don't know the IP address of the NAS. When everything was working it was always 192.168.11.33 but I can't ping this nor is it showing up in my router's list of active DHCP clients. The fvdw-sl console is starting up with a NAS address of 192.168.11.252 (which I also can't ping or see in my DHCP active clients list).

I tried doing the procedure with both of those IPs set in the "IP Address for NAS" field in the console.

In both cases I did not see a status bar after the shell window with the "provided by fvdw\nwaiting for u-boot.." came up. Very quickly another shell pops up and disappears, followed eventually with the telnet window which eventually fails with "connection to 192.168.11.[33,252]/telnet timed out.

Following the guidelines from here https://plugout.net/viewtopic.php?f=7&t=2645, I validated the following:

-- I have only one wired network adaptor enabled on my windows machine. It can see other devices on my LAN.
-- Wireless ethernet adaptor is disabled. VPN adaptor was deleted.
-- I selected the UIMAGE-3142-KIRKWOOD-171-standalone image
-- I have disabled the windows defender firewall

At some point I found a help file that had this information in it:
"ip address NAS and telnet server:
The telnet server in the standalone kernel will be accessible using one these three ip addresses:
xxx.yyy.zzz.252 The address as shown in the main console window, in which the first three octets are equal to those of the pc running the console
192.168.1.251 (use this when devices in your LAN have ip addresses starting with 192.168.1.xxx)
192.168.0.251 (use this when devices in your LAN have ip addresses starting with 192.168.0.xxx)
Be sure that the the mentioned ip addresses are not used by other devices in your LAN."

Since my DHCP is set up to use 192.168.11.x naming convention I think that 252 was the correct ending for the IP, but I also tried the standalone kernel procedure with the NAS address set to 192.168.11.251 just in case.

One last observation that may be of interest to you. I noticed that the shell window that says "waiting for u-boot" disappears VERY quickly. By the time I bend over to turn the NAS on it is gone, long before the disks have spun up.

Anyhow, I appreciate your help as always!
jpjpjp
Donator VIP
Donator VIP
 
Posts: 23
Joined: Wed Jan 28, 2015 12:48 am

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby fvdw » Sun Feb 12, 2023 5:35 am

If the window waiting for uboot disappears before switching on your ns2 this can only happen if you have another device in your lan is responding to broadcast messages of the console.
Furthermore you should see the loading of the standalone kernel in the console window before it disappears and the telnet window opens.
Does the window waiting for uboot remains open if you don't power up the nas?
fvdw
Site Admin - expert
 
Posts: 13239
Joined: Tue Apr 12, 2011 2:30 pm
Location: Netherlands

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby jpjpjp » Sun Feb 12, 2023 4:16 pm

Thanks fvdw! Yes I can confirm that the "waiting for uboot" window was disappearing quickly even with the ns2 powered off. To get around this problem I disconnected everything from the router except my windows pc and the nas, disabled wifi and rebooted the router. In this configuration the kernel load worked! Here is the output that jocko asked for:

Code: Select all
root@fvdw-sta-kirkwood:/ # mkdir sda7
root@fvdw-sta-kirkwood:/ # mount /dev/sda7 sda7
root@fvdw-sta-kirkwood:/ # cat sda7/boot.log
start boot log
detect and set platform
nwsp2
UIMAGE-395-199
nwsp2
update dev nodes
booting using sda2 file system...
else loop1 finished
rcS finis
root@fvdw-sta-kirkwood:/ # mkdir sda2
root@fvdw-sta-kirkwood:/ # mount /dev/sda2 sda2
root@fvdw-sta-kirkwood:/ # cat sda2/boot.log
start boot log
detect and set platform
nwsp2
kirkwood
UIMAGE-466-KIRKWOOD-7
Current kernel: 4.6.6 #7 PREEMPT Sun May 7 11:50:52 CEST 2017
nwsp2
 mount dev/pts
update dev nodes
booting using sda2 root file system...
make dev node for buttons...
make dev node for tun device...
enable IP forwarding...
start buttons control daemon
device = nwsp2
source = buttons-nwsp2
buttons-nwsp2 daemon started
Fri Feb 10 17:51:07 UTC 2023
create temporary passwd file
run udevstart to update dev nodes when necessary
inserting kernel modules:
modprobe: module 'iscsi_trgt' not found
create temporary group file
configure loopback network interface
setting reboot and standby
nwsp2
rebootd-nwsp2
nwsp2
standbyd-nwsp2
starting php based setup routines step 1
 * Initialize the volatile db file...    [ OK ]
 * Starting udevd...                                     [ OK ]
 * Finishing restore RAID devices...     [ OK ]
 * Found database configuration file...  [FAIL]
 database corrupt !
Loading the bak copy of the database !
 * Updating Disks database...                    [ OK ]
 * Starting mount of volumes...
 * Finishing mount of volumes...                 [ OK ]
 * Generating Hosts File...                      [ OK ]
 * Configuring System Hostname...                [ OK ] 
 * Configuring LAN interface... cannot start udhcpc process.
 * Initializing Timezone...                      [ OK ]
 * Starting web server...
Warning: Invalid argument supplied for foreach() in /etc/finc/sysfunc_password_configure.finc on line 24
                                 [ OK ]
 * Starting mount of internal USB ...
 * Finishing mount internal USB ...      [ OK ]
 * Configuring Disks...                                  [ Fail ]
 * Configuring Samba...                                  [ OK ]
 * Configuring System Users...
        Root password: use default password
        Set users, linux and samba accounts      [ OK ]
 * Starting Fvdw-sl Discovery Daemon...  [ OK ]
start rpcbind service
starting php based setup routines step 2
 * Starting dropbear...                                  [ OK ]
 * Kill temporary dropbear...                    [ OK ]
starting php based setup routines step 3
 * Starting daemon update Hosts File...  [ OK ]
 * Starting mount of remote shares...
 * Finishing mount shares...                     [ OK ]

Warning: Invalid argument supplied for foreach() in /etc/finc/dm_get_volume_addons.finc on line 54  # JP Note: (lots of times)

Warning: Invalid argument supplied for foreach() in /etc/finc/dm_get_volume_addons.finc on line 79  # JP Note: (lots of times.   About 5 of 54, then 5 of 79, repeating many times)

starting php based setup routines step banner


*** fvdw-sl NAS firmware
    This is fvdw-sl version: fvdw-sl 17.0
    built on: May 28 2017

    LAN IP address: 127.0.0.1 (static)

    Port configuration:

    LAN   ->
php based setup routines finished
web permission on resolv.conf
set device tuning for dms performance
move smbd en nmbd db files away from ram disk to prevent hanging samba server
LED settings
else loop1 finished
rcS finished
root@fvdw-sta-kirkwood:/ #



Hope this info is helpful. Thanks fvdw once again for the suggestion to reduce competing "stuff" on the network!
jpjpjp
Donator VIP
Donator VIP
 
Posts: 23
Joined: Wed Jan 28, 2015 12:48 am

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby Jocko » Sun Feb 12, 2023 5:13 pm

Hi

Indeed it is a useful output

Your nas database is corrupted and then there is several errors
* Configuring LAN interface... cannot start udhcpc process.
Starting web server...
Warning: Invalid argument supplied for foreach() in /etc/finc/sysfunc_password_configure.finc on line 24
* Configuring Disks... [ Fail ]
So no udhcp client is running and your nas can not get its ip from your router

Then I suggest you to download your database and send it to me by pm (because it contents some passwords). I will repair it and I will explain later how to upload

So still with the action "Standalone kernel, load and start" (or repeat from the beginning if you closed the session), do
Code: Select all
mkdir /sda5
mount /dev/sda5 /sda5
busybox tftp -r nas_back_db_nok.xml -l /sda5/rw_fs/etc/nas_back_db.xml -p ip-laptop
where ip-laptop is the ip of your laptop

You should find the file nas_back_db_nok.xml in the subfolder tfp. Then compress it before sending it by pm
Jocko
Site Admin - expert
 
Posts: 11367
Joined: Tue Apr 12, 2011 4:48 pm
Location: Orleans, France

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby jpjpjp » Mon Feb 13, 2023 3:24 pm

Jocko, Replying here in case this is helpful for anyone else.

I ran into a problem with your instructions:

root@fvdw-sta-kirkwood:/ # busybox tftp -r nas_back_db_nok.xml -l /sda5/rw_fs/etc/nas_back_db.xml -p 192.168.11.2
0
tftp: can't open '/sda5/rw_fs/etc/nas_back_db.xml': No such file or directory
root@fvdw-sta-kirkwood:/ # ls /sda5
etc nas_conf_db_ok.xml usr
lost+found tmp var


Since I couldn't find any rw_fs directory I thought instead to grab the one db that I could see:

root@fvdw-sta-kirkwood:/ # busybox tftp -r nas_back_db_nok.xml -l /sda5/nas_conf_db_ok.xml -p 192.168.11.20
nas_back_db_nok.xml 100% |****************************************************************| 6535 0:00:00 ETA

Will send this to you via PM. If there's something else I should try to get the file that you asked for please let me know.

Thanks as always
jpjpjp
Donator VIP
Donator VIP
 
Posts: 23
Joined: Wed Jan 28, 2015 12:48 am

Re: Bricked NS v2 after setting miniDLNA to run automaticall

Postby Jocko » Mon Feb 13, 2023 5:48 pm

Hi

I am sorry there was an error with my last post :oops:

So the right command is
Code: Select all
mkdir /sda5
mount /dev/sda5 /sda5
busybox tftp -r nas_conf_db_nok.xml -l /sda5/rw_fs/etc/nas_conf_db.xml -p ip-laptop


And on the same time, maybe the other outputs would be useful later :
Code: Select all
ls -al /sda5/rw_fs/etc
ls -l  /sda5/rw_fs/nas_conf_db_ok.xml
df /sda5

nas_conf_db_ok.xml is a backup of the nas database performed manually by the user from the fw web-interface. So if it is too old, it won't be used to restore the nas database
Jocko
Site Admin - expert
 
Posts: 11367
Joined: Tue Apr 12, 2011 4:48 pm
Location: Orleans, France

Next

Return to Lacie Network Space vs2 and max version

Who is online

Users browsing this forum: No registered users and 3 guests