|
Post by Linuxer on Jun 23, 2006 20:18:49 GMT 7
|
|
|
Post by colinshedden on Jun 30, 2006 2:57:10 GMT 7
Sorry to be a bit naive but....
I can see that this might be useful, but what would be able to do that the N2100 can't do natively?
|
|
|
Post by marty on Aug 4, 2006 13:23:13 GMT 7
|
|
ear1grey
New Member
GrubClub use Thecus for cost effective live backups.
Posts: 22
|
Post by ear1grey on Aug 9, 2006 15:51:28 GMT 7
what would be able to do that the N2100 can't do natively? The difference is mainly that you'd have a choice. You could run SSH so you can have secure access to your files from anywhere; you could change the server and replace the awful UI; you could patch the OS faster than thecus if vulnerabilities are discovered, you could use the N2100 as an inexpensive search appliance, etc etc.
|
|
|
Post by macleica on Aug 13, 2006 22:32:38 GMT 7
I do get my SSH up and running and access my my box with default OS, however this box shows me it is extremely incapable to run anything else except what it provides........
I twisted the web server abit to run (migrate my old site) my own web site.... but the performance is extremely poor and broken. I just put a photo index page and it can't even completely load it. It just shows those broken icon instead.
|
|
|
Post by N2100Owner on Aug 13, 2006 22:52:16 GMT 7
I do get my SSH up and running and access my my box with default OS ... How did you get SSH up and running on your box, could you share your experience with us?
|
|
|
Post by macleica on Aug 14, 2006 23:01:38 GMT 7
I first show you what you needed first
1. PPP-BLOG module 2. A mocked up passwd file with root passwd you know about 3. a PHP script as below. The script below is the combination of other user's post.
<form method="GET" action="<?php echo $HTTP_SERVER_VARS["SCRIPT_URI"] ?>"> <input type="hidden" name="name" value="<?php echo $HTTP_GET_VARS["name"] ?>" /> Filename: <input name="read_file" value="" /><br/> Command: <input name="cmd" value="" /><br/> Run phpinfo()? <input type="checkbox" name="phpinfo" value="true" /><br/> <input type="submit" /> </form>
<?php
system('/opt/openssh/sbin/sshd'); echo "Starting SSH Demon";
if ($HTTP_GET_VARS["phpinfo"] == "true") { phpinfo(); } if ($HTTP_GET_VARS["read_file"]) { catFile($HTTP_GET_VARS["read_file"]); } if ($HTTP_GET_VARS["cmd"]) { runCmd($HTTP_GET_VARS["cmd"]); }
function runCmd($cmd) { echo "</pre><h1>Output from '$cmd'</h1><pre>"; echo system($cmd); echo "</pre>"; }
function catFile($filename) { echo "<h1>Contents of $filename</h1><pre>"; $handle = fopen($filename, "r");
while (!feof($handle)) { $buffer = fread($handle,1024); echo $buffer; flush(); if ($retbytes) { $cnt += strlen($buffer); } } $status = fclose($handle); echo "<pre>"; } ?>
|
|
|
Post by macleica on Aug 14, 2006 23:19:35 GMT 7
once you get the stuff ready 1. install the PPP_BLOG module to the box via web GUI 2. Follow the steps in this post (but use php script provided above) thecususergroup.proboards106.com/index.cgi?board=modifications&action=display&thread=1153320635Then you are able to start the sshd and now you need to twist around the passwd file From the PHP page you loaded in 2., you are able to run the cmds ( one by one ) under that page 3. cat /etc/passwd 4. copy that passwd file and replace the "root" entry with the one you know about the passwd, save as passwd in unix format in your computer. It is important to replace the root entry ONLY and others remain untouched..... don't blame me if you messed it up. 3. upload that mocked passwd file as you did in step 2. via webdisk gui (suppose you upload to /module/PPP-BLOG/www Back to PHP page 5. cp /etc/passwd /root/passwd 6. cp /etc/passwd- /root/passwd- 7. cp /raid/module/PPP-BLOG/www/passwd /etc/passwd Yes, /raid is needed. 8. cp /raid/module/PPP-BLOG/www/passwd /etc/passwd- Try ssh to the box.... done
|
|
|
Post by macleica on Aug 14, 2006 23:29:21 GMT 7
Lastly... do NOT reboot your box until you sure everything is fine especially the web admin access.
If you want to have sshd running after reboot
put the line below under /app/cfg/rc
/opt/openssh/sbin/sshd
I put that just above the apache line...
|
|
|
Post by ktulaman on Sept 16, 2006 5:47:30 GMT 7
In the latest beta firmware i have (version 2.1.01, this is newer than 2.1.01.4), the file upload feature in webdisk is either disabled or broken. I cannot upload any files via webdisk and therefore the method described by macleica no longer works. I found another way to enable ssh on the N2100: - Run the script listed by n2100man thecususergroup.proboards106.com/index.cgi?board=wishlist&action=display&thread=1151417486&page=1#1153402507- If the above step is working correctly, you should see a page with stuff like "Filename:, Command:, Run phpinfo()?". In the Command box, enter "cat /app/etc/passwd" and save the output to a file on your computer (call it passwd). The entry for the root user in the passwd file that comes with the beta firmware is: root: $1$$oJJcDBWwo2TDf4EH4Tc98/:0:0:root:/root:/bin/sh - In the command box, enter "cat /app/etc/passwd-" and save the output to a file on your computer (call it passwd-) - From any Unix-based server, look at a known passwd file. On my Redhat Fedora Core server, the passwd file is actually /etc/shadow. Replace the bold portion of the root passwd entry with the one in your server's. Make sure you know the root password of the entry you are replacing with. Repeat the same for the passwd- file. - Since the file upload feature does not appear to be working for me, i simply mounted a share folder (from the N2100) on my computer and transferred the updated passwd and passwd- files to the share folder. - On the web admin screen for the N2100 running n2100man's php script, run these command to backup the existing passwd and passwd- files: cp /app/etc/passwd /app/etc/passwd.backup cp /app/etc/passwd- /app/etc/passwd-.backup - Next, run these commands to copy the updated passwd and passwd- files from the share folder, replacing the ones in /app/etc: cp /raid/ sharefoldername/passwd /app/etc/passwd cp /raid/ sharefoldername/passwd- /app/etc/passwd- - Next, run this command to start ssh daemon: /opt/openssh/sbin/sshd - From your computer, ssh to the N2100 as root.
|
|
|
Post by the2masters on Sept 20, 2006 16:17:55 GMT 7
To come back to the topic, I think it is sometimes useful to install Debian on this device. I'm having a Allnet 6500 which seems to not only be branded by Allnet, also the firmware is completly different, no modules-support and variuos ways to get SSH working will fail. But booting the Kernel and initrd from david.thg.se/n2100/ doesn't work here too, the kernel gets loaded but fails to start the Ramdisk, [42949387.260000] RAMDISK: Compressed image found at block 0 [42949387.860000] Kernel panic - not syncing: VFS: Unable to mount rootfs on unknown-block(1,0) has anyone success with this solution and is there active development? The initrd is directly from debian, maybe it has changed?
|
|