Topic: built in server questioins

I was trying to edit the index.html file under www yesterday, but I found that it was read only.  I tried to change it so that it would be writable, but It said it was a read only file system.
how do i make it a not read only file system.

and how much space is left over on the chumby to add my html files and images to?(or will I have to make links to the usb?)

sorry if my question seems stupid, i'm only 13.

Re: built in server questioins

There is no way to change the file system to read/write without reflashing the entire device with a custom firmware image.

My suggestion is this - if you want to set up a web server on the chumby, follow these instructions instead.  Toward the bottom of that page, you'll see I've posted an already-built implementation of a full lighttpd web server ready to run.  You can skip the instructions on how to build it from scratch if you like.

The chumby itself does not have any substantial amount of read/write storage - it's intended that you enhance the behavior of the device using USB flash drives.

Good luck!

Re: built in server questioins

ln -s is about to become your best friend tongue

Re: built in server questioins

zachninme wrote:

ln -s is about to become your best friend tongue

Actually, I'm not sure that would help for our friend sevc - one can't change the file system to replace the current index.html with a symbolic link to somewhere else, at least on Ironforge.  Katamaris (alpha prototypes) could do it because their file systems were read/write and thus a bit more vulnerable to bricking.

Incidentally, sevc, your question was not stupid at all, and I encourage you to ask any questions you like.  I'm *paid* to know what I'm doing, and I ask apparently stupid questions all the time. It's the best way to find stuff out - I typically find out how stupid I am wink

Re: built in server questioins

Oooh, right... I forgot.

Just a question, on Ironforge -- how would one add something as an executable, like in /usr/bin? Is that just not possible at all anymore?

Re: built in server questioins

I tried the thing but when I go to my chumby's main page, it still shows the index.html file from the built in server.

furthermore, when I click on the wireless link, it says that It's unable to connect. it does the same if Itry to go to any other folders.

the only things I changed on the files you had on the wiki were:



1.  in lighttpd.conf, I changed these two lines

server.errorlog = "/dev/null/lighttpd.error.log"
accesslog.filename = "/dev/null/lighttpd.access.log"


2. and in debugchumby I got rid of these two lines

# create the log directory
mkdir /tmp/logs

(i did that thinking I won't need them)



Did I do something wrong?

Re: built in server questioins

Hmmm, not sure - what editor did you use to edit the files?  The chumby wants UNIX-style line endings.

The lines should actually read:

server.errorlog = "/dev/null"
accesslog.filename = "/dev/null"

...since /dev/null is a driver, not a directory.

You should probably ssh into the chumby and see what processes are running.  Since you're still getting the builtin server, it does seem that the "debugchumby" script isn't working, because one of the things it does is kill the builtin server.

Re: built in server questioins

zachninme wrote:

Oooh, right... I forgot.

Just a question, on Ironforge -- how would one add something as an executable, like in /usr/bin? Is that just not possible at all anymore?

You'd put the binary on the USB flash drive and set the PATH environment variable accordingly.

Re: built in server questioins

Wow!  I changed the dev/null thing and it worked!  thanks. smile

Re: built in server questioins

Congratulations!

Re: built in server questioins

The server works fine at my home computers, but when I go to school (i'm there right now), I get this when I typein the IP address:

Proxy Encountered Error 
Connection Timeout: Could not contact the remote server. Possible causes include mistyped URL, transient network problems, overloaded remote server, and misconfigured proxy server. 


Is this because of my school's computers, a chumby problem, or my mistake?

Re: built in server questioins

It depends upon how your home network is set up.

If you have some sort of router hanging off a cable or DSL modem, you'd have to forward port 80 from the router to your chumby.

This would be the case if the IP of your chumby is something like 192.168.x.x or 10.x.x.x, or maybe 172.22.x.x.

Even if you do forward the port, many ISPs block port 80 in order to prevent folks from hosting web servers out of their homes.

Re: built in server questioins

I have a 192.168.x.x address.

what do I do to make it work?

Re: built in server questioins

If your school has a proxy server, it may require you to enter some (or all) of the following:

1) The proxy server address
2) The proxy port number
3) A proxy username
4) A proxy password

Some schools (typically K-12) do this to control access from a school's network.

Re: built in server questioins

sevc wrote:

I have a 192.168.x.x address.

what do I do to make it work?

Ok, this means that you're probably using some sort of router behind some kind of DSL or cable modem.  That address will not work except from other computers in your home.

If you log into the admin interface of your router, (probably 192.168.1.1), you'll be able to forward port 80 to the chumby's IP.  You'll need to be using a computer at your home to do this. Your router will also have information about the public IP for your modem - that's the address you'll need to use from your school.

According to our logs, some of your forum posts come from the 70.177.x.x netblock, which appears to be a residential Cox account in the Washington DC area, which is presumably your home.  *That's* the public IP that you'd use to access your chumby from outside your home, once you've forwarded the port. I also see your posts from your school, which is in Fairfax County.

Think of your router as a multiline phone system, where the "192.168.x.x" IP is the local "extension", and the "70.177.x.x" address is the main number.  WHat you're doing by port forwarding is saying that all calls coming into the main number go to a particular extension.

The manual for your router can explain this in more detail.

Re: built in server questioins

OK, I logged into the admin thing and looked around for a minute.  I didn't see anything relating to port forwarding.  Is there another name for it, or should I just look more?

our router is a lynksis model no. wrt54gs if it helps.



also, my parents are a bit unhappy about the idea of changing any of these settings.  are you sure that everything will be exactly as it should be?  I'd get in lots of trouble if I broke something.

Re: built in server questioins

On most Linksys routers, it's under the "Advanced" tab, under "Forwarding".

I certainly agree with your parents that you should be very careful, and make changes only with their permission, and only when you completely understand exactly what you're doing and why.

Re: built in server questioins

OK, I did it.  However, when I type in the IP address into the address bar, It continues loading forever.
Is this because I'm trying to do this from within my house, or something else?
(can I ssh into my chumby from other places also, or does that use another port?)

Re: built in server questioins

SSH uses a different port (22)

20 (edited by dnkorte 2007-10-23 09:53:50)

Re: built in server questioins

sevc - your "internal" IP (the one for your in-house LAN, in your case 192.168.x.x) is different than your "external" IP, which is assigned by your ISP, and may or may not change from time to time depending on the nature of your broadband service (do you have a "Static IP" or a "Dynamic IP"; static IP accounts typically cost more, and are much less common.  For many residential accounts, the first number of an external IP is 64 or 68 or 76 but it can be almost anything less than 256 EXCEPT for 192, 172, 127, or 10).  Anyhow you'll have to check with your ISP to figure that out. 

Your router performs the translation between the external address and the internal one, and can spread out a limited number of external addresses into enough internal addresses to support all the computers you may have in your home.  The port mapping the Duane has suggested is one of the many ways of creating the association or "mapping"  between the real world and one particular machine within your home.

In any event, when you're at school or anywhere outside of your house you'll need to talk to the "external IP" address.  So instead of typing "192.168.x.x" into your browser, you'll need to type a different address, like "68.2.48.x" or something...

When you're at home, you'll need to talk to the "internal IP" address (192.168.x.x).  Same destination, but different addresses depending on where you are when you're talking.  Confusing, but its the way it works.

Sounds to me like you're typing the 192.168.x.x and it hangs because your browser is trying to find a local machine (at your school) with that address and there probably isn't one.

btw you can also map port 22 (the ssh port) to a specific machine, using the same technique

Re: built in server questioins

I went back and checked the settings.  apparently I had put in the wrong IP address.
I changed it to the right address and now, when I type in my house's IP address. I get the page from my chumby.

However, I called someone else to see if he could get to it, and he couldn't.
what  do I do next?







P.S. How are the people at chumby industries doing with the fires?

Re: built in server questioins

sevc wrote:

P.S. How are the people at chumby industries doing with the fires?

Well, about half of us were evacuated from our homes - I just returned to mine, which was in one of the very few areas from which they lifted the evacuation order.

The Chumby headquarters is still in the mandatory evacuation area - we've all been working from home or wherever we've been evacuated to.

Most of the servers that run the Chumby Network are in a data center far away from the fires.

Re: built in server questioins

Stay safe, guys.  Can't imagine what it must be like to go through all that sad

Chumby birthdate: 10/11/07

Re: built in server questioins

sevc wrote:

I went back and checked the settings.  apparently I had put in the wrong IP address.
I changed it to the right address and now, when I type in my house's IP address. I get the page from my chumby.

However, I called someone else to see if he could get to it, and he couldn't.
what  do I do next?

According to the Cox High Speed Internet page, they block incoming connections on ports 25 (SMTP), 80 (HTTP), 135-139, 445, 1433, 1434 and 1900.

You should consider running the server on another unblocked port, like 8080.  You'd have to alter the lighttpd.conf file and change your Linksys's routing accordingly, at which point you would access your server at http://70.177.x.x:8080/whatever

25 (edited by sevc 2007-10-24 17:58:25)

Re: built in server questioins

YAY!  It works.:)  (kinda)


The first time I did it I just got a black screen with big font that said chumby.

I unplugged it, brought it to the side of my computer, anticipating lots of work, but tried it one last time.
to my surprise it showed my page.
I then called my friend, who got my page also.



The strange thing is, I don't have a file like the one that showed up on my chumby...





my theory is that when the chumby is farther away from the router, It has a hard time working with it. (computers in my house have low signal on the second floor)
Is it possible that i'm right? If so, is there a way to fix it other than to move it closer?