Unfortunately no one can be told what fun_plug is - you have to see it for yourself.
You are not logged in.
Has anyone done any work on adding SNMP management to this unit?
I'm assuming that it just needs a kernel module or something similar that can be added through the fun_plug, but since my linux knowledge has been mostly acquired in this forum, figuring out what to do is a little beyond me.
Any ideas? Am I totally wrong in my assumption? Is it easier? Is it harder? Is this a ridiculous question?
Offline
You will have to compile a snmp daemon and start it from fun_plug.
For instance snmpd. However this will eat up preciouses memory as everything running.
Offline
Hi Fordem,
The SNMP Agent of choice in the Linux world is Net-SNMP: http://www.net-snmp.org/
However, for such a device like the DNS-323, you would need a tailored MIB / Agent that would reflect the status information you can obtain via the Web Console.
Could be cool to program, actually
Cheers,
Loïc.
Offline
ldomaigne wrote:
Hi Fordem,
The SNMP Agent of choice in the Linux world is Net-SNMP: http://www.net-snmp.org/
However, for such a device like the DNS-323, you would need a tailored MIB / Agent that would reflect the status information you can obtain via the Web Console.
Could be cool to program, actually
Cheers,
Loïc.
better it seems to me to have ie. telnet running through funplug, than running some scripts for
1. uptime
2. fanspeed
3. temperature
4. hdd space
of course webinterface could also possible, but you have to login everytime and scrape content
Offline
zeroday wrote:
better it seems to me to have ie. telnet running through funplug, than running some scripts for
1. uptime
2. fanspeed
3. temperature
4. hdd space
Better, perhaps not. But easier to implement!
Cheers,
Loic.
Offline
Has anyone written snmp monitoring for this unit yet?
Offline
Due to a nice feature of the DNS, you capture any info you want off the box by going to the different info pages in the /proc directory via the built in web server.
Ie
http://dns323/proc/version
http://dns323/proc/cpuinfo
http://dns323/proc/net/arp
etc...
CD to /proc and do an ls -l to figure out all the stuff you can read via simple http requests.
Regards,
bspvette
Offline
One thing to note about the above, It works on F/W 1.05, but not on 1.04.
Offline
My 323 arrived yesterday and whilst I'm waiting for it to finish backing up my system I wrote a Vista Gadget thing to monitor it. So far I can of course display all the stuff I can get from the web server pages, and I've got a "shut down" and "restart" button - you know the sort of thing. I'm too lazy to log into the thing to check how it is and muck about with it.
It's hardly SNMP and I have to poll, but at last I know what's up with the thing.
Those /proc references are precisely what I need to add a few more features. However as I can't actually telnet to the thing, I can't actually get a list of all the things I could get there... would someone care to post a full list? I'll publish the gadget once it's done, if anyone can't think of a better way to do this.
Offline
it will be interesting to see your code/gadget. At one point I had a html page on my d/t performing the "post" to simulate the shutdown button click, but your solutions sounds nicer :-)
hth.
lu
Offline
Thanks for the list - I'll have a poke about with that the next time it rains, if no one else suggests an easier way to do this.
I just put the gadget here:
http://www.wigglesworld.klebos.com/stuf … efault.asp
The version there (0.3) is slightly brain-damaged as the "shut down" and "restart" functions aren't enabled - I'm in the middle of a big multi-day backup to this box so I can't test shut down/ restart, although those should be trivial to implement.
All polite feedback/ suggestions welcome, although I don't guarantee to take notice of it. As I've only the one system here to test on, there may be some crass defect which prevents it working for others for all I know.
This is basically doing the same POST thing you mention; you could run it on a web server except for a few "gadget" specific surrounding things which I only just learned about.
Offline
I notice that your gadget asks for the username/password for the dns323. The security is only half hartedly implemented (search this forum) though and is a bit of a joke really. Saying that you could argue that it is designed for the home market. You don't need to login to access the files in /proc or /etc - just point your webbrowser at them and hey presto, so some of the stuff you are looking to display you may not even need to log in for! So you are left to secure the box yourself (i.e. router security etc). Indeed I have just noticed that the 323 exposes the details of your email account (inc. pw), oops!
As to suggestions, although the unit has a feature to force-shutdown the box on reaching a certain temp, it may be nice if your gadget can store green/amber/red temp values (user specified) with the display showing the temp in green/amber/red so the automatic *force*-shutdown does not have to be used. Just a suggestion (which many may think useless!)
lu
Last edited by luusac (2008-09-19 21:35:56)
Offline
Yeah, I noticed that. I even managed to kill the www server on it without being logged in... definitely you don't want to expose that server to the wild internet! Fortunately killing the www didn't kill the box, as my day-and-a-half backup is still running and I don't want to check if it fails sensibly on that! Whilst it's a bit careless, it's a domestic machine as you say.
I like the idea of red/green/amber - I'll put it on the list.
Offline
if you haven't already, look on the wiki for ffp - very useful, and should you need to host any web stuff on the box it comes with lighthttp.
lu
Offline
philw wrote:
The version there (0.3) is slightly brain-damaged as the "shut down" and "restart" functions aren't enabled - I'm in the middle of a big multi-day backup to this box so I can't test shut down/ restart, although those should be trivial to implement.
To get the shutdown to work I had to uncomment the line
makeServerRequest( "/goform/sysShutDown", "GET", null, null ); //Get tools page.
Note that I also had to change the POST to a GET. I haven't spared any thought yet as to why I needed to do this given your code.
A few other suggestions:
password field should show asterisks when typing (change type="text" to type="password" on the relevant line in settings.html)
pressing your reload button displays plain text password - not sure how to change this other than not to display it on refresh/reload (i.e. remove the code which fetched the pwd)
change function of 'refresh stats' to 'restart dns' - as you mention on your webpage the 'reload gadget' serves the same function (which I see is already on your todo list)
allow tickboxes in the options page to allow user selection of individual items - i.e. some people may not need dns/gw/mac address etc displayed and may prefer something else instead.
colour buttons :-)
I mentioned previously that logging in was not required to shutdown the unit or for some other purposes. Various complaints have been made about the security on the dns323, and in the future, who knows, dlink may actually do something about this - which would break you gadget if you do modify it. But in any case the dns323 admin web interface (that you are using to populate the gadget) is irrelevant and unnecessary to access files in /proc and /etc
As to signing the gadget look here: it seems pretty simple. Also see http://msdn.microsoft.com/en-us/library/bb498012.aspx
cheers
lu
Offline
Thanks; all good stuff. I finally finished my monster backup so I made the shut down thing work in 0.4 because I could test it. I found the POST error - you just need to GET the page; there's nothing to post. My mistake on the original. I rewrote my http stuff completely as I can see what I should do with this next anyhow.
Other stuff - I put it on the list.
I had a look at the *nix commands and I think I'll make the thing multi-page with the output of those things. Or I'll worry about something else - I'd forgotten why I disliked Unix so much but now it's all coming back to me.
Offline
Ok I finished that as far as I'm going with it for now - the version at the link above has pretty restart/ shutdown buttons and multiple pages of data from the NAS.
Pages:
network : Not much use as they don't change.
status: usage and temperature graphs, configurable temperature colouring
os: garbage from *nix plus the uptime as hh:mm:ss
clients: client IP address lists
Buttons:
refresh (there's also a configurable background refresh timer)
restart
shut down
Settings for all the stuff I think needs to be a setting.
That's version 0.7.
------
limitations: only implemented for a single disk NAS, no RAID.
-------
Other stuff:
I went through the other god-awful /proc commands, some of which crashed the www server on the NAS. I did think of implementing a "crash www server" button, but on balance I decided to ignore all those I could see no use for.
It's table-driven so it's pretty easy to add other commands - you just need to know the url and the format of the output. Then add an entry into the state-table for the command, with a reference to the formatter to parse the output from it.
Offline
Does it work for XP as well? Well, i guess I'll just try it........
Offline
I will try XP WIndows Then i will tell you...
-----------------------------------------
SNMP Scanner
Offline