DSM-G600, DNS-3xx and NSA-220 Hack Forum

Unfortunately no one can be told what fun_plug is - you have to see it for yourself.

You are not logged in.

Announcement

#1 2009-01-06 00:01:16

maxk
New member
Registered: 2009-01-05
Posts: 4

web access lost after config file edit

Hi,

I can no longer access the web admin page of my DNS-323 after I edited the configuration file, changing "security = SHARE" to "security = USER". I followed the procedure described in
http://dns323.kood.org/howto:bettersamb … _unc_paths

My unit has FW v1.05 (no fun_plug)

After loading the config file back onto the DNS-323 and a reboot I have no more access to the administration pages. I used Notepad++ for editing the file (UNIX format), so I'm sure that I didn't add any CR/LFs to the config file.

http://<DNS-323 IP address>/ returns a "server not found" error.

I still can ping the DNS-323 and I also have access to the data (~900 GBs...).

I am afraid of doing a hardware reset as this will delete all user and access rights information and I might not be able to restore it in case I should still have no access to the admin page?

Any help on how to get the web server running again would be very much appreciated.
Thx in advance Max

Offline

 

#2 2009-01-06 02:44:53

luusac
Member
Registered: 2008-04-29
Posts: 360

Re: web access lost after config file edit

either ffp it or just get a telnet fun_plug running.  Then open a console and use your favourite an editor like vi or nano to open the config file and confirm that there are only unix line endings.

Offline

 

#3 2009-01-06 11:42:15

maxk
New member
Registered: 2009-01-05
Posts: 4

Re: web access lost after config file edit

Thanks for the quick reply. I hoped I could avoid installing the fun_plug as I am not a linux techie... Just needed to get around the UNC paths problem to access the DNS-323 via a popcorn hour A-110.

I checked the config file with Notepad++ *before* uploading it ("view all characters") - and yes: there are only LFs at the line endings. Isn't this enough proof? Sorry for this newbie question.

Offline

 

#4 2009-01-06 11:54:00

mig
Member
From: Seattle, WA
Registered: 2006-12-21
Posts: 532

Re: web access lost after config file edit

Perhaps reading this post will give you some ideas.
Concepts should still be valid with fw1.06 and ffp v0.5
http://dns323.kood.org/forum/t2011-Help … DNS32.html

Last edited by mig (2009-01-06 11:57:21)


DNS-323 • 2x Seagate Barracuda ES 7200.10 ST3250620NS 250GB SATAII (3.0Gb/s) 7200RPM 16MB • RAID1 • FW1.03 • ext2 
Fonz's v0.3 fun_plug http://www.inreto.de/dns323/fun-plug

Offline

 

#5 2009-01-06 15:50:35

luusac
Member
Registered: 2008-04-29
Posts: 360

Re: web access lost after config file edit

as to proof - it is always better to check the file and see what is actually in it rather than trusting that it is ok.  At least that way you can rule out file corruption/wrong line endings as a possible cause.  As to ffp / telnet installing them is very easy.  In the case of ffp it is just copying two files then a reboot, and in the case of just telnet not much more (see the wiki how to telnet/how to ffp for instructions)

Offline

 

#6 2009-01-07 00:05:45

maxk
New member
Registered: 2009-01-05
Posts: 4

Re: web access lost after config file edit

mig wrote:

Perhaps reading this post will give you some ideas.
Concepts should still be valid with fw1.06 and ffp v0.5
http://dns323.kood.org/forum/t2011-Help … DNS32.html

Thanks for the hint. I seem to have a similar problem. I installed fun_plug and accessed the device via telnet. A ps command revealed that the webserver isn't running. When trying to start it via /web/webs I get:

Code:

Quota Stop
Set Daylight :/usr/sbin/daylight 2 &
country = 32
Daylight mode : NONE
StartDaylight EU = March 29
EndDaylight EU = October 25
/web/ddns.conf:2: no such option '-----------------------------7d9d7a2a0928--'
Segmentation fault

I guess the ddns.conf is corrupted. Having no experience with commandline I have no idea on how to edit this file and am a bit worried to brick my DNS-323 by doing anything wrong.

Offline

 

#7 2009-01-07 10:34:36

luusac
Member
Registered: 2008-04-29
Posts: 360

Re: web access lost after config file edit

I think that the seg fault you mention has been discussed in another thread - search the forum.

Offline

 

#8 2009-01-07 11:04:47

mig
Member
From: Seattle, WA
Registered: 2006-12-21
Posts: 532

Re: web access lost after config file edit

I agree your ddns.conf seems to be corrupted.  You need to create a new ddns.conf.

May I first suggest reading some tutorials about Linux http://dns323.kood.org/forum/t2648-Gett … Linux.html
these may get you more comfortable with using the command line.

The following procedure should get your web GUI up and running, with minimal command line.

First create an new ddns.conf using the following text.  Select the text (this is the contents of my ddns.conf)
and paste it into a windows editor, use notepad or notepad++.

CF-DDNS-ENABLE = "0"
CF-DDNS-USERNAME = ""
CF-DDNS-PASSWORD = ""
CF-DDNS-DOMAIN = ""
CF-DDNS-SERVER = ""
CF-DDNS-TIMEOUT = "2073600"

Then save this new file as ddns.conf to the root of your DNS-323 (just like the fun_plug install).

Next, telnet to your DNS-323 and remove any dos linefeeds in the ddns.conf file using the following command:

dos2unix  /mnt/HD_a2/ddns.conf

Next, move the ddns.conf file to the /web directory using the following command:

mv  /mnt/HD_a2/ddns.conf  /web/

Next, set the ddns.conf file to the correct file permission using the following command:

chmod 755 /web/ddns.conf

Then, start the web GUI with the following command

/web/webs

If the web GUI is started successfully, use your web browser and navigate to the
Tools->ddns page of the DNS-323 web gui.  Make a simple change to one setting,
like change enable to disable (or vice versa) and click the save settings button on
the ddns page.  This should update the ddns.conf file in NVRAM.

You should be able to power off and restart you DNS-323 and the web GUI should be
running on startup

Good Luck

Last edited by mig (2009-01-07 18:04:39)


DNS-323 • 2x Seagate Barracuda ES 7200.10 ST3250620NS 250GB SATAII (3.0Gb/s) 7200RPM 16MB • RAID1 • FW1.03 • ext2 
Fonz's v0.3 fun_plug http://www.inreto.de/dns323/fun-plug

Offline

 

#9 2009-01-07 23:26:21

maxk
New member
Registered: 2009-01-05
Posts: 4

Re: web access lost after config file edit

I followed your elaborate advice step by step - and it worked!! The web server is up again and also restarted after a reboot.

Thank you very much, indeed. I hope that this step-by-step explanation will be helpful as well for others who might run into a similar problem in the future.

What I still don't understand: I had followed the procedure described on the wiki for editing the DNS-323 configuration file. The edited file which I uploaded had *no* CR/LF line endings (I checked that again). How could this still result in such a mess?

Offline

 

#10 2009-01-07 23:47:20

mig
Member
From: Seattle, WA
Registered: 2006-12-21
Posts: 532

Re: web access lost after config file edit

Glad your DNS-323 is working again, Max.  Hopefully, you were able to understand
how each step was needed to get to the solution.

I don't know how (why?) the reload of the edited configuration file
messed up the web GUI, but you are not the first person to have this
trouble.

I have never been an advocate of editing the config file to increase functionality,
because of the potential of the web gui crash.

If you want to add USER security to your samba config (/etc/samba/smb.conf file)
you should try to follow the procedure described in this post
http://dns323.kood.org/forum/t1232-wher … ed%3F.html

Last edited by mig (2009-01-08 07:30:22)


DNS-323 • 2x Seagate Barracuda ES 7200.10 ST3250620NS 250GB SATAII (3.0Gb/s) 7200RPM 16MB • RAID1 • FW1.03 • ext2 
Fonz's v0.3 fun_plug http://www.inreto.de/dns323/fun-plug

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB