Did anyone get things working with mysql 5 ? There is a package in the repository, but it does not want to start after install. phpmyadmin does not install after installing mysql5.
Does it still require recompling?
Printable View
Did anyone get things working with mysql 5 ? There is a package in the repository, but it does not want to start after install. phpmyadmin does not install after installing mysql5.
Does it still require recompling?
I don't think mysql 5 is ever going to work on these routers actually, probably because it's software design is a bit different compared to mysql4.
Also mysql5 requires more resources, and that while mysql4 only pulls of about 100kb/s max;)
in the end mysql 4 can do the same things mysql 5 can, apart from some really specialized stuff hardly used in regular webpackages :)
recompiling won't work either because the compiler on the router has problems with c++.
You might be able to pull it off with the crosscompiler after a bit of work :)
Hello,
I followed the tutorial. No errors shown during the process.
However, when I try to start lighttpd it gives this error:
Starting web server: lighttpd
2010-08-01 18:29:11: (network.c.589) SSL: Private key does not match the certificate public key, reason: error:02001002:system library:fopen:No such file or directory /opt/etc/lighttpd/lighttpd.pem
Of course, I checked for the file existence and it is not there. But should it? Why is there SSL certificate check?
Anyhow, I spent last couple of hours searchingg for a solution, but did not find any. (I am not linux guru, so I might be missing something).
Only change to the original tutorial is that I have my www root in /tmp/harddisk/www and I have changed the path in one of the tutorial commands accordingly.
Any ideas?
Thanks.
Brano.
Hi all,
well, I did start the server after all :) but I am not sure whether I did the right thing.
I went to the config file and commentted out everything around the SSL server thing (at the end of config) - this was the part referencing the PEM file.
Now, server starts and works. But was this the right thing to do? Am I missing something because of that? I suppose https :)
Cheers,
Brano.
SSL isn't configured in the config file, for that you need to do some things yourself:)
You can make a self signed pem file yourself like this:
you need openssl installed for thatQuote:
openssl req -new -x509 -keyout server.pem -out server.pem -days 365 -nodes
now for the lighttpd config file (just add it somewhere):
This creates a separate socket with sslQuote:
$SERVER["socket"] == ":443" {
#### SSL engine
ssl.engine = "enable"
ssl.pemfile = "/opt/etc/lighttpd/server.pem"
server.document-root = "/harddisk/mnt/www"
}
this way your site works via http and https
try it out on my site, I've been running that for a month or so: https://wpte.kicks-ass.net/
Now obviously browsers say its unsafe since it's not signed by a known company.
You can still import it for general accepted certificates tho, but for windows you need something like a .der file
this is how you convert the pem file to a der file:
Quote:
openssl x509 -in server.pem -inform PEM -out server.der -outform DER
I'm going to update this how-to soon btw, since I found out I have 3 major errors in it :)
Hi!
I just installed everything according to the 1.st post.
I got 3 problems, 2 of them are solved in this forum, they were:
1.) When using the ipkg eaccelerator, server gives internal error 500 when the extension of a file is *.php, but it works well with *.html.
solution: do the manual install.
2.) couldn't connect to the mysql, something about authorization error
solution: delete or comment the 20.th line of my.cnf that says password
And finaly the one i cannot find anywhere.
3.) I dumped a database from my wamp installation.
mysqldump kruh > kruh.sql;
i moved this file to my router, executed it with
source kruh.sql;
everything works fine, i am able to run selects, for instance select(*) from users; gives me 4.
But i cannot get this to work in php.
My code:
This returns nothing :(Code:$db_host = 'localhost';
$db_user = 'bady';
$db_pass = '';
$db_data = 'kruh';
// ---------------------------------------------------
$link=mysql_connect($db_host,$db_user,$db_pass);
if(!$link) die("unable to connect: ".mysql_error());
mysql_select_db($db_data,$link);
$x=mysql_result(mysql_query("select count(*) from users",$link),0);
echo $x;
If i change the select to "select NOW() from dual" it works fine, so im connected to DB. What am i doing wrong?
EDIT: this solved the problem:
typed this in mysql console: grant all privileges on *.* to ''@'localhost';
Hi,
I've created .pem and .der files with openssl after which I've added lines proposed by Wpte to lighttpd.conf file. Restart of lighttpd and no monit about certificate under https:// address. Should I have 443 port forwarded or what?
What exactly happens?
you can see your webpages in https?
or isn't it encrypted at all?
@badyto
I know there are serious problems with the how-to at the moment due to updated ipkg packages.
Unfortunately I haven't found the time to fully test my findings.
The updated how-to will be shorter and easier to understand
Basically when i try to connect thru https:// i don't get a reply, no 501 or 404 error just time out in FireFox and IE 8. I've tried to add this
but it didn't helped at all. Thru http:// I can use my site but not thru https://Code:$HTTP["scheme"] == "https" {
server.document-root = "/www/servers/www.example.org/secure/"
}
You mentioned port forwarding as well?
if you're in the local network of your router no port-forwarding is needed
but for external access you can add a basic iptables rule like this to your firewall:
in the end, the config settings I wrote in my previous post should be all to make https work.Quote:
iptables -A INPUT -p tcp --dport 443 -j ACCEPT
I've double checked it in my config
Added iptables rule and didn't helped still can't use SSL connections. Maybe something is wrong with my .conf file, could you look into it?
Edit: This is new when I've entered local IP - https://192.168.1.1 a certificate notification appeared so it works, but why not on my external IP?
Good to know it works locally:)
Just as the "server.port = 8081" the ssl socket should bind to every network interface.
if it's not the modem that requires an extra firewall setting you might try these config changes:
not sure if they work, but it's worth tryingQuote:
$SERVER["socket"] == "0.0.0.0:443"{
...
$SERVER["socket"] == "127.0.0.1:443"{
...
I do think it's something with the firewall tho, since:
(as moderator I can see your ip, no worries;))Quote:
x.x.x.x isn't responding on port 443 (https).
This didn't helped either, still no ssl connections but on local IP it works (sic!). Also I've tried some of this tutorial on port changing.
did that, restarted router and sure web-gui works fine but no website on my router (port changed from 8081 to 80 like in tut). Also I removed 1 rule from iptables which I thought is not usefull any more, this was:Code:nvram set http_lanport=8080
nvram commit
Any ideas what's wrong, lighty is working according to htop.Code:iptables -t nat -A VSERVER -p tcp -m tcp --dport 80 -j DNAT --to-destination 192.168.1.1:8081 # przekierowanie www
Edit: Https:// connection with address https://ex.ip:8081 works but why not with https://ex.ip ?
I know that lighttpd is a bit strict when it comes to ports...
have you tried to set the standard port to 80 + my config code?
if that works, it might be a lighttpd bug, or setting I'm not aware of:confused:
https://ex.ip:8081 doesn't work for me here