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

#51 2008-05-17 20:38:31

knireis
Member
Registered: 2007-12-10
Posts: 231

Re: MySQL on DNS-323

cab wrote:

The reason why I wanted Mysql was install of slimserver or Squeezecenter - but I haven't succeded yet.
Has anyone tried installing this piece of software - prereqs are perl and Mysql.

I succeeded in getting slimserver 6.3 to work, but i would like 6.5.4. But i haven't managed that one yet.
For instructions:
http://dns323.kood.org/forum/t2012-Tuto … .4%29.html

Offline

 

#52 2008-05-18 01:53:23

Henkie-Penkie
Member
Registered: 2008-05-10
Posts: 6

Re: MySQL on DNS-323

forre wrote:

What is going wrong?

can you post the errors in the /ffp/var/mysql/*.err

Hi,

first of al i am trying to start mysql with "mysqld_safe &"    (is this the right way to do this????)
This is what i see(see below) , cursor won't come back unless i hit enter.

/mnt/HD_a2/ffp # /ffp/bin/mysqld_safe &
/mnt/HD_a2/ffp # 080518 01:42:17 mysqld_safe Logging to '/ffp/var/mysql/CH3SNAS.err'.
080518 01:42:17 mysqld_safe Starting mysqld daemon with databases from /ffp/var/mysql
080518 01:42:17 mysqld_safe mysqld from pid file /ffp/var/mysqld.pid ended

after the enter hitting i get this:  "[1] + Done                       /ffp/bin/mysqld_safe"

this is in the error file.

080518 01:39:43 mysqld_safe Starting mysqld daemon with databases from /ffp/var/mysql
080518  1:39:43 [Warning] option 'thread_stack': unsigned value 65536 adjusted to 131072
080518  1:39:43 [ERROR] Can't start server: Bind on TCP/IP port: Address already in use
080518  1:39:43 [ERROR] Do you already have another mysqld server running on port: 3306 ?
080518  1:39:43 [ERROR] Aborting

080518  1:39:43 [Note] /mnt/HD_a2/ffp/libexec/mysqld: Shutdown complete

080518 01:39:43 mysqld_safe mysqld from pid file /ffp/var/mysqld.pid ended

after seeing this i thought i had it figured out, so i stopped the mysql on my computer but i does not make any difference.

Hope you can make something out of this???

Greets Henk.

Offline

 

#53 2008-05-18 02:45:07

forre
Member
Registered: 2008-04-22
Posts: 26

Re: MySQL on DNS-323

I seams that a program already using port 3306.

type:
ps | grep mysqld
to check if mysqld already is running.

It is a start script in /ffp/start for mysqld. If this file has execution rights, then mysqld is starting when you boot the device.

try:
sh /ffp/start/mysqld.sh stop
sh /ffp/start/mysqld.sh start

Offline

 

#54 2008-05-18 08:57:23

Henkie-Penkie
Member
Registered: 2008-05-10
Posts: 6

Re: MySQL on DNS-323

forre wrote:

I seams that a program already using port 3306.

type:
ps | grep mysqld
to check if mysqld already is running.

It is a start script in /ffp/start for mysqld. If this file has execution rights, then mysqld is starting when you boot the device.

try:
sh /ffp/start/mysqld.sh stop
sh /ffp/start/mysqld.sh start

oke done that, this is the result.

/mnt/HD_a2 # ps | grep mysqld
20683 root     /bin/sh /ffp/bin/mysqld_safe
20903 root     /mnt/HD_a2/ffp/libexec/mysqld --basedir=/mnt/HD_a2/ffp --datadir=                                         /ffp/var/mysql --user=root --log-error=/ffp/var/mysql/CH3SNAS.err --pid-file=/ff                                         p/var/mysqld.pid --socket=/ffp/var/mysql.sock --port=3306
20912 root     /mnt/HD_a2/ffp/libexec/mysqld --basedir=/mnt/HD_a2/ffp --datadir=                                         /ffp/var/mysql --user=root --log-error=/ffp/var/mysql/CH3SNAS.err --pid-file=/ff                                         p/var/mysqld.pid --socket=/ffp/var/mysql.sock --port=3306
20913 root     /mnt/HD_a2/ffp/libexec/mysqld --basedir=/mnt/HD_a2/ffp --datadir=                                         /ffp/var/mysql --user=root --log-error=/ffp/var/mysql/CH3SNAS.err --pid-file=/ff                                         p/var/mysqld.pid --socket=/ffp/var/mysql.sock --port=3306
  405 root     grep mysqld

/mnt/HD_a2 # sh /ffp/start/mysqld.sh stop
WARNING: mysqld_safe: Not running

/mnt/HD_a2 # sh /ffp/start/mysqld.sh start
WARNING: mysqld_safe: Already running

now is mysql running or not????   strange results if you ask me ???

Offline

 

#55 2008-05-18 11:14:23

forre
Member
Registered: 2008-04-22
Posts: 26

Re: MySQL on DNS-323

The mysqld was already running

connect by typing
mysql -u root

mysql> show databases;
mysql> quit;

if you type ls -la /ffp/start/my*
and the you can find if the start scipt has execution rigts (the x in "-rwxr-xr-x")

I think everything is ok.

Offline

 

#56 2008-05-18 11:29:03

Henkie-Penkie
Member
Registered: 2008-05-10
Posts: 6

Re: MySQL on DNS-323

forre wrote:

The mysqld was already running

connect by typing
mysql -u root

mysql> show databases;
mysql> quit;

if you type ls -la /ffp/start/my*
and the you can find if the start scipt has execution rigts (the x in "-rwxr-xr-x")

I think everything is ok.

Hi,

this did not work at first, but after rebooting things started to work properly i think.
i have no clue why at first it did not work.

anyway thnx for helping out.
grtz

Offline

 

#57 2008-05-18 12:57:53

Henkie-Penkie
Member
Registered: 2008-05-10
Posts: 6

Re: MySQL on DNS-323

Hi there,

now that mysql is up and running i succesfully installed kplaylist.
at the moment its adding 63414 mp3's to the database (wonder how long this is going to take). smile
hope its not going to freeze up.

Grtzz Henk.

Offline

 

#58 2008-05-22 06:47:45

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

I get this error "ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)"
when I try this /ffp/bin/mysql_secure_installation and it prompts me for New password.. here no matter what I type.. my root passwd or leaving it blank.. after I hit enter.. I get the above mentioned Error..

What could be the problem?.. i've installed mysql and php-mysql from the funpkg site.. that all went well.

Offline

 

#59 2008-05-22 23:18:13

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

bump... please help me out here guys.. I've tried uninstalling php and mysql and reinstalling them.. but still the same socket error when I got to configure the mysql root password.. I'm trying to do this so that I can install ampache.

Offline

 

#60 2008-05-22 23:47:59

raid123
Member
Registered: 2008-04-30
Posts: 22

Re: MySQL on DNS-323

Try doing chmod 777 on /tmp?

Offline

 

#61 2008-05-23 02:50:13

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

that still doesn't seem to help.. I have installed
mysql-5.1.23-rc-2.tgz & also php-5.2.6-mysql-1.tgz

from this website http://81.216.140.39/dns-323/mysql_and_php/

After this, I did the mysql_db_install and it gave me..

========================================

Installing MySQL system tables...
080522 16:36:48 [Warning] option 'thread_stack': unsigned value 65536 adjusted to 131072
OK
Filling help tables...
080522 16:36:48 [Warning] option 'thread_stack': unsigned value 65536 adjusted to 131072
OK

To start mysqld at boot time you have to copy
support-files/mysql.server to the right place for your system

PLEASE REMEMBER TO SET A PASSWORD FOR THE MySQL root USER !
To do so, start the server, then issue the following commands:

/ffp/bin/mysqladmin -u root password 'new-password'
/ffp/bin/mysqladmin -u root -h dlinkNAS password 'new-password'

Alternatively you can run:
/ffp/bin/mysql_secure_installation

which will also give you the option of removing the test
databases and anonymous user created by default.  This is
strongly recommended for production servers.

See the manual for more instructions.

You can start the MySQL daemon with:
cd /ffp ; /ffp/bin/mysqld_safe &

You can test the MySQL daemon with mysql-test-run.pl
cd /ffp/mysql-test ; perl mysql-test-run.pl

Please report any problems with the /ffp/bin/mysqlbug script!

The latest information about MySQL is available at http://www.mysql.com/
Support MySQL by buying support/licenses from http://shop.mysql.com/
==========================================

Then after this I do the following... just to check if mysql is running..

======
# mysqld_safe &
# 080522 16:37:11 mysqld_safe Logging to '/ffp/var/mysql/dlinkNAS.err'.
080522 16:37:12 mysqld_safe A mysqld process already exists

[1] + Done(1)                    mysqld_safe
root@dlinkNAS:/mnt/HD_a2/ffp/tmp# ps | grep mysqld
5414 root     /bin/sh /ffp/bin/mysqld_safe --syslog
5553 root     /ffp/libexec/mysqld --basedir=/ffp --datadir=/ffp/var/mysql --user=root --pid-file=/ffp/var/mysqld.pid --socket=/ffp/var/mysql.sock --port=3306
5554 root     logger -t mysqld -p daemon.error
5555 root     /ffp/libexec/mysqld --basedir=/ffp --datadir=/ffp/var/mysql --user=root --pid-file=/ffp/var/mysqld.pid --socket=/ffp/var/mysql.sock --port=3306
5556 root     /ffp/libexec/mysqld --basedir=/ffp --datadir=/ffp/var/mysql --user=root --pid-file=/ffp/var/mysqld.pid --socket=/ffp/var/mysql.sock --port=3306
10078 root     grep mysqld
====================

Then I get to the part of ......
root@dlinkNAS:~# /ffp/bin/mysql_secure_installation




NOTE: RUNNING ALL PARTS OF THIS SCRIPT IS RECOMMENDED FOR ALL MySQL
      SERVERS IN PRODUCTION USE!  PLEASE READ EACH STEP CAREFULLY!


In order to log into MySQL to secure it, we'll need the current
password for the root user.  If you've just installed MySQL, and
you haven't set the root password yet, the password will be blank,
so you should just press enter here.

Enter current password for root (enter for none):
ERROR 2002 (HY000): Can't connect to local MySQL server through socket '/tmp/mysql.sock' (2)
Enter current password for root (enter for none):
================================

As you see.. this is where i get stuck in a loop.. and I have to quit terminal service and re-telnet..

ALSO NOTE:

I downloaded the php.ini file from the above mentioned website (from where I downloaded the packages).. and put that under /ffp/etc

I haven't made any changes to it.


WHAT AM I DOING WRONG? WHAT I SHOULD I DO?.. ALSO.. HERE IS THE .ERR FILE

======================================
080521 19:35:50 mysqld_safe Starting mysqld daemon with databases from /ffp/var/
080521 19:35:50 [Warning] option 'thread_stack': unsigned value 65536 adjusted t
080521 19:35:50 [Note] Event Scheduler: Loaded 0 events
080521 19:35:50 [Note] /mnt/HD_a2/ffp/libexec/mysqld: ready for connections.
Version: '5.1.23-rc'  socket: '/ffp/var/mysql.sock'  port: 3306  Source distribu
080521 19:43:04 [Note] /mnt/HD_a2/ffp/libexec/mysqld: Normal shutdown

080521 19:43:04 [Note] Event Scheduler: Purging the queue. 0 events
080521 19:43:04 [Note] /mnt/HD_a2/ffp/libexec/mysqld: Shutdown complete

080521 19:43:04 mysqld_safe mysqld from pid file /ffp/var/mysqld.pid ended
080521 20:02:22 mysqld_safe A mysqld process already exists
080521 20:39:19 mysqld_safe A mysqld process already exists
080521 22:54:49 mysqld_safe A mysqld process already exists
080521 22:56:23 mysqld_safe Starting mysqld daemon with databases from /ffp/var/
080521 22:56:23 [Warning] option 'thread_stack': unsigned value 65536 adjusted t
080521 22:56:23 [Note] Event Scheduler: Loaded 0 events
080521 22:56:23 [Note] /ffp/libexec/mysqld: ready for connections.
Version: '5.1.23-rc'  socket: '/ffp/var/mysql.sock'  port: 3306  Source distribu
080521 23:06:13 [Note] /ffp/libexec/mysqld: Normal shutdown

080521 23:06:13 [Note] Event Scheduler: Purging the queue. 0 events
080521 23:06:13 [Note] /ffp/libexec/mysqld: Shutdown complete
===================================================

NOW I AM WONDERING...

why is it looking under /tmp for the mysql.sock???? I don't see that file being in there.. Do i need to define the path of mysql.sock in some configuration file?? What is the problem here? I have downloaded the php.ini and put it in the /etc without modifying anything.. I assumed the author of those packages have them all working together..

Offline

 

#62 2008-05-23 02:55:53

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

ACTUALLY LET ME ADD THIS..

I DID CHANGE the php.ini file to UNCOMMENT the extension=mysql.so line

Offline

 

#63 2008-05-23 02:58:40

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

AM I SUPPOSED TO HAVE a my.cnf ALSO in the /ffp/etc???

Offline

 

#64 2008-05-23 05:10:17

raid123
Member
Registered: 2008-04-30
Posts: 22

Re: MySQL on DNS-323

Sorry, I'm trying to recollect what I did to get MYSQL working.  I'm not sure if I added this line, but I do have this in my mysqld.sh:

ln -s /ffp/var/mysql.sock /tmp/mysql.sock

The package didn't work for me the first time either.  I had to make some tweaks to get it to work, and I think this may be one of them.  There may be a way to repoint the sock file to /ffp/var, but at least this line got me up and running.

Last edited by raid123 (2008-05-23 05:13:36)

Offline

 

#65 2008-05-23 05:17:31

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

Hey.. thanks for your reply.. I tried that.. the socket error has gone.. but now when I do the

/ffp/bin/mysql_secure_installation



It tells me..

Enter current password for root (enter for none): (I hit enter here)

ERROR 1045 (28000): Access denied for user 'root'@'localhost' (using password: NO)

Enter current password for root (enter for none):

I don't know why it says access denied.. I am logged in as root
any ideas???

Offline

 

#66 2008-05-26 05:22:34

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

bump

Offline

 

#67 2008-06-15 18:20:16

pwvandeursen
Member
Registered: 2007-07-04
Posts: 112

Re: MySQL on DNS-323

fonz wrote:

anyone tried forre's packages,yet?
http://81.216.140.39/dns-323/mysql_and_php/

I tried this some time ago and got it working in the end. However I wanted to have imagemagick working as well so installed it from fonz's site, but after that my mysql got broken so I need to reinstall it again....(unless someone knows why it could be the case and knows how to solve it.

So I wanted to go back to the site above, but the link doesn't work anymore......

How can I get it again, and get Mysql and imagemagick working together?

Thanks
Patrick

Offline

 

#68 2008-06-15 19:49:15

forre
Member
Registered: 2008-04-22
Posts: 26

Re: MySQL on DNS-323

The server will be working until tomorrow.

// forre

Offline

 

#69 2008-06-15 22:11:03

pwvandeursen
Member
Registered: 2007-07-04
Posts: 112

Re: MySQL on DNS-323

Thanks forre, just got it working again.
anybody know why after installing imagemagick from fonz that the mysql installtion got broken? How can I get imagemagick working in this setup?

Offline

 

#70 2008-06-19 00:45:29

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

i finally got mysql working with php!!.. whew!!.. hey no body told me that I was supposed to use the php.ini.recommeded file from the examples folder under /ffp/etc/examples.. smile.. I had downloaded some php.inp from fonz's website and that was giving me all the socket errors, permission errors etc..

so I used the one under /ffp/etc/examples.. and transferred it over to /ffp/etc
Then I opened up the my.cnf under the same /ff/etc and then copied the location of the .socket into the the php.ini and uncommented the mysql.so (which by the way is misspelt in the php.ini).. and then got it to working by using the
/ffp/bin/mysqladmin -u root password 'new-password'
/ffp/bin/mysqladmin -u root -h dlinkNAS password 'new-password'

so that is settled!!

I also downloaded the imagemagick from fonz's website and installed it without any problems.. I wonder where you got stuck with the installation!!

I have succesffuly loaded Ampache (www.ampache.org) for my music collection.. and coppermine photo gallery (http://coppermine-gallery.net/).. once I got the mysql running..

Both work great!!

Offline

 

#71 2008-06-19 11:02:17

pwvandeursen
Member
Registered: 2007-07-04
Posts: 112

Re: MySQL on DNS-323

What steps did you follow to install imagemagick?

Offline

 

#72 2008-06-26 01:23:07

emailpr
Member
Registered: 2008-05-17
Posts: 38

Re: MySQL on DNS-323

I downloaded imagemagick from fonz's website. and installed it using funpkg -i file_name.tgz

Offline

 

#73 2008-08-20 17:05:56

forre
Member
Registered: 2008-04-22
Posts: 26

Re: MySQL on DNS-323

I have compiled mysql-5.1.26-rc from release candidate tree and mysql-5.0.67 from GA tree for FFP 0.5.

Changelogs:
http://dev.mysql.com/doc/refman/5.1/en/news-5-1-x.html
http://dev.mysql.com/doc/refman/5.0/en/ … es-cs.html

http://81.216.140.39/dns-323/mysql_and_php/

NOTE! /ffp/etc/my.cnf are deleted after upgrade. Make a backup on this file!

I've got segmentation fault every time I tried to compile mysql. I could fix this by recompiling and installing
gcc, uclibc, make, autoconf and automake, in that order.

I do not know which of these packages that ocuured segmentation fault when compiling.

Last edited by forre (2008-08-20 17:12:18)

Offline

 

#74 2008-10-01 00:46:16

WildSioux
Member
Registered: 2007-03-05
Posts: 71

Re: MySQL on DNS-323

forre...

I believe I managed to install your mysql package with fonz fun plug v5.  I don't know if it is working properly though.  I tried some of the commands from above and it said all was working properly. 

I can get into something using:  mysql -u "localhost"

However, how do I find out what my username and password is?  Also, instead of root, I can get into "localhost."  Don't know how that happened.

Thanks

Offline

 

#75 2008-10-01 11:57:55

forre
Member
Registered: 2008-04-22
Posts: 26

Re: MySQL on DNS-323

WildSioux wrote:

I can get into something using:  mysql -u "localhost"

It is OK. You can check soem with following commands:

Code:

mysql -u "localhost"
mysql> show databases;
+--------------------+
| Database           |
+--------------------+
| information_schema | 
| test               | 
+--------------------+
2 rows in set (0.00 sec)

mysql> use information_schema;
Database changed
mysql> select * from USER_PRIVILEGES;
+----------------+---------------+----------------+--------------+
| GRANTEE        | TABLE_CATALOG | PRIVILEGE_TYPE | IS_GRANTABLE |
+----------------+---------------+----------------+--------------+
| ''@'localhost' | NULL          | USAGE          | NO           | 
+----------------+---------------+----------------+--------------+
1 row in set (0.00 sec)

WildSioux wrote:

[However, how do I find out what my username and password is?  Also, instead of root, I can get into "localhost."  Don't know how that happened.

When installing mysql, the user root exist without any password

do same commands after login as root to see the differencis (mysql -u root)

To change root password, see earlier message from emailpr

Offline

 

Board footer

Powered by PunBB
© Copyright 2002–2010 PunBB