You are not logged in.
It starts fine:
[root@server ~]# /etc/rc.d/mysqld restart
:: Stopping MySQL [DONE]
:: Starting MySQL [DONE]
[root@server ~]#BUT, it no longer works:
http://doorknob60.is-a-geek.org/wiki
http://doorknob60.is-a-geek.org/wordpress
Both give errors, as well as Phpmyadmin. I can't seem to find any relevant log files either. I tried some random stuff, but nothing seems to work. I just got MySQL set up on this box about 2 days ago, then an update comes around and messes it up again ![]()
Last edited by doorknob60 (2009-11-18 23:57:58)
Offline
Did you read the front page? You need to update the PHP config to point to the new location of the pid and sock files.
http://www.archlinux.org/news/473/
Last edited by SiB (2009-11-18 23:18:12)
Offline
Yes, I did read that. Even after messing with config files it doesn't work. And PHP config? I'll assume that's a typo. What all do you have to change? Everything looks fine on my current my.cnf file, I think at least.
# mysql config file for medium systems.
#
# This is for a system with little memory (32M - 64M) where MySQL plays
# a important part and systems up to 128M where MySQL is used together with
# other programs (like a web server)
#
# One can in this file use all long options that the program supports.
# If you want to know which options a program support, run the program
# with --help option.
# The following options will be passed to all MySQL clients
[client]
password = ~password removed~
port = 3306
socket = /var/run/mysqld/mysqld.sock
# Here follows entries for some specific programs
# The MySQL server
[mysqld]
port = 3306
socket = /var/run/mysqld/mysqld.sock
datadir = /var/lib/mysql
pid_file = /var/run/mysqld/mysqld.pid
skip-locking
key_buffer = 16M
max_allowed_packet = 1M
table_cache = 64
sort_buffer_size = 512K
net_buffer_length = 16K
myisam_sort_buffer_size = 8M
# Don't listen on a TCP/IP port at all. This can be a security enhancement,
# if all processes that need to connect to mysqld run on the same host.
# All interaction with mysqld must be made via Unix sockets or named pipes.
# Note that using this option without enabling named pipes on Windows
# (via the "enable-named-pipe" option) will render mysqld useless!
#
#skip-networking
# Replication Master Server (default)
# binary logging is required for replication
#log-bin
# required unique id between 1 and 2^32 - 1
# defaults to 1 if master-host is not set
# but will not function as a master if omitted
server-id = 1
# Replication Slave (comment out master section to use this)
#
# To configure this host as a replication slave, you can choose between
# two methods :
#
# 1) Use the CHANGE MASTER TO command (fully described in our manual) -
# the syntax is:
#
# CHANGE MASTER TO MASTER_HOST=<host>, MASTER_PORT=<port>,
# MASTER_USER=<user>, MASTER_PASSWORD=<password> ;
#
# where you replace <host>, <user>, <password> by quoted strings and
# <port> by the master's port number (3306 by default).
#
# Example:
#
# CHANGE MASTER TO MASTER_HOST='125.564.12.1', MASTER_PORT=3306,
# MASTER_USER='joe', MASTER_PASSWORD='secret';
#
# OR
#
# 2) Set the variables below. However, in case you choose this method, then
# start replication for the first time (even unsuccessfully, for example
# if you mistyped the password in master-password and the slave fails to
# connect), the slave will create a master.info file, and any later
# change in this file to the variables' values below will be ignored and
# overridden by the content of the master.info file, unless you shutdown
# the slave server, delete master.info and restart the slaver server.
# For that reason, you may want to leave the lines below untouched
# (commented) and instead use CHANGE MASTER TO (see above)
#
# required unique id between 2 and 2^32 - 1
# (and different from the master)
# defaults to 2 if master-host is set
# but will not function as a slave if omitted
#server-id = 2
#
# The replication master for this slave - required
#master-host = <hostname>
#
# The username the slave will use for authentication when connecting
# to the master - required
#master-user =
#
# The password the slave will authenticate with when connecting to
# the master - required
#master-password =
#
# The port the master is listening on.
# optional - defaults to 3306
#master-port = <port>
#
# binary logging - not required for slaves, but recommended
#log-bin
# Point the following paths to different dedicated disks
#tmpdir = /tmp/
#log-update = /path-to-dedicated-directory/hostname
# Uncomment the following if you are using BDB tables
#bdb_cache_size = 4M
#bdb_max_lock = 10000
# Uncomment the following if you are using InnoDB tables
#innodb_data_home_dir = /var/lib/mysql
#innodb_data_file_path = ibdata1:10M:autoextend
#innodb_log_group_home_dir = /var/lib/mysql
#innodb_log_arch_dir = /var/lib/mysql
# You can set .._buffer_pool_size up to 50 - 80 %
# of RAM but beware of setting memory usage too high
#innodb_buffer_pool_size = 16M
#innodb_additional_mem_pool_size = 2M
# Set .._log_file_size to 25 % of buffer pool size
#innodb_log_file_size = 5M
#innodb_log_buffer_size = 8M
#innodb_flush_log_at_trx_commit = 1
#innodb_lock_wait_timeout = 50
[mysqldump]
quick
max_allowed_packet = 16M
[mysql]
#no-auto-rehash
# Remove the next comment character if you are not familiar with SQL
#safe-updates
[isamchk]
key_buffer = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M
[myisamchk]
key_buffer = 20M
sort_buffer_size = 20M
read_buffer = 2M
write_buffer = 2M
[mysqlhotcopy]
interactive-timeoutAlso, is there some place I'm missing when looking for error logs? I'm looking in /var/log and see nothing related to mysql
Last edited by doorknob60 (2009-11-18 23:28:47)
Offline
You need to edit the php.ini file located in the /etc/php/ folder.
Birger ![]()
Last edited by MindTooth (2009-11-18 23:48:29)
Offline
Wow, it would've been nice if somewhere it specified that, because to me, that's not obvious at all. I never needed to edit that part of the php.ini file until just now (all I had to do before was uncomment the extension = mysql.so line or whatever). Thanks though, it seems to be working now ![]()
Offline
Yea it's weird, I clearly remember seeing on the front page that you needed to edit the php.ini but now it's gone!
Offline
Weird, it's not even in the mailing list email that I got though...
Offline
Resolved, how???
I have set mysql.default_socket = /var/run/mysqld/mysqld.sock in php.ini, and socket = /var/run/mysqld/mysqld.sock in my.conf (double set, client and mysqld).
httpd, and mysqld restarted without problems. When i try:
# mysql_config --socket
/tmp/mysql.sockwhy answer is /tmp/mysql.sock?
In phpMyAdmin I recive:
Error: 2002 (CR_CONNECTION_ERROR)
Message: Can't connect to MySQL server
Korab
Offline
Did you do this for the MySQLi section also? Afaik, you don't need to edit my.cnf.
Birger ![]()
Offline
@MindTooth thank you, MySQLi section was missed. Now works perfectly ![]()
Korab
Offline
I updated the php.ini as requested but I still get the error of Korab.
edit I just had to restart also the apache server. Now works
Last edited by Berseker (2009-11-19 12:06:49)
Offline
Still mysql refuses to start for me.:(
Edited php.ini, also the MySQLi section, my.cnf. Did chown mysql:mysql /var/lib/mysql -R and restarted apache, but it does not work?
Any further ideas?
:: Starting MySQL [FAIL]also
sudo mysql_config --socket
/tmp/mysql.sockLast edited by Urfaust (2009-11-19 16:26:18)
Offline
@Urfaust
are you using mysql 5.1.41-2? check logs
Offline
@Urfaust
are you using mysql 5.1.41-2? check logs
Aaaaaaargh, I Syu'ed 10 minutes ago and mysql was updated, thought this was the last version but it is 5.1.41-1..
I'm waiting until my mirror is in sync and put myself to shame until then. Thanks.
Offline
Hi all--
fixing phpadmin, mysql query browser, etc. was not a problem.
My problem is with the mysql python bindings = MySQLdb = mysql-python in pacman. Doing a "pacman -Ql mysql-python" does not find any files that look like a config file. Randomly browsing the *.py files doesn't find anything either. Can somebody point me in the right direction for fixning this? (BTW: sqlalchemy appears to be broken, too. I don't even want to think about that yet.)
Is there help in mysql-5.1.41-2? I'm still running mysql-5.1.41-1 and don't see -2 in my mirror. (In any case I am traveling and really, really bad download speed, so I don't really want to do an update.) I have temporarily fixed the problem by downgrading to mysql-5.1.39.
thanks
Offline
Could some please explain in layman terms what needs to be edited in /etc/php/php.ini ?
This is the first time I meddled with this and I have no idea what to edit where to get mysql to start up.
Offline
This should be fixed with the latest updates. I think that the PHP update also forces an update on the php.ini file. Either look for php.ini.pacsave or php.ini.pacnew.
Birger ![]()
Offline