The Community Forums

Interact with an entire community of cPanel & WHM users!
  1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

DNSONLY update modified mysql-pw last night

Discussion in 'Bind / DNS / Nameserver Issues' started by henker, Jan 16, 2009.

  1. henker

    henker Well-Known Member

    Joined:
    May 1, 2003
    Messages:
    60
    Likes Received:
    0
    Trophy Points:
    6
    Since version 11.x, updates really suck.
    After almost every update, something is terribly broken - and I thought I ran STABLE for a good reason...

    Anyway, what happened last night on a DNSONLY server:

    >Running Cleanups......Done
    >Updating services & databases......Done
    >Cpanel updates are coming from layer2.cpanel.net
    >Setting Up Crontab......Done
    >Running Named Checks......Done
    >Updating MySQL Server...Updates for mysql are disabled because /etc/mysqldisable exists.

    Yeah, I wish.
    Not only did cPanel CHANGE the root pw, it also modified /root/.my.cnf - which caused a lot of issues for me - this was on a production MySQL server
    running a replication setup.
    Could somebody *please* let me know why this was necessary ?

    Regards,

    henker
     
  2. dave9000

    dave9000 Well-Known Member

    Joined:
    Apr 7, 2003
    Messages:
    891
    Likes Received:
    1
    Trophy Points:
    16
    Location:
    arkansas
    cPanel Access Level:
    Root Administrator
    It did it to ours too. We run dns only and also run a seperate mysql database on this server and the update added the /etc/mysqldisable, changed the root password on mysql and caused me quite a bit of headache.
     
  3. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    DNSONLY now requires mysql to be installed for brute force protection. If you have a valid /root/.my.cnf with the correct password in it, your password will not be changed.
     
  4. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    It should start at system boot now. It will also monitor it if you have that enabled in the Service Manager.
     
  5. dave9000

    dave9000 Well-Known Member

    Joined:
    Apr 7, 2003
    Messages:
    891
    Likes Received:
    1
    Trophy Points:
    16
    Location:
    arkansas
    cPanel Access Level:
    Root Administrator
    Does this new setup stop and restart mysql on its own ?
     
  6. henker

    henker Well-Known Member

    Joined:
    May 1, 2003
    Messages:
    60
    Likes Received:
    0
    Trophy Points:
    6
    I assume this is valid for future updates ? In our case, cPanel overwrote the existing .my.cnf - and changed the root pw accordingly.
     
  7. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    It shouldn't have overwritten your config if mysql worked from the command line as root.
     
  8. henker

    henker Well-Known Member

    Joined:
    May 1, 2003
    Messages:
    60
    Likes Received:
    0
    Trophy Points:
    6
    I'm not arguing that "it shouldn't have overwritten my config" - I wonder why it actually did.
    And seriously, I really wonder why almost *every* update has issues lately.
    Even on "STABLE", a simple Apache update has many issues - it wasn't like that in the pre-cPanel-11 era...
     
  9. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    Please run /scripts/mysqlconnectioncheck and let me know if it resets the mysql password again. If this is the case then there is a bug in mysqlconnectioncheck (or you are out of disk space).

    I couldn't find any threads or tickets about problems with updating apache from you. Please let me know what happened.

    Thanks
     
  10. yanayun

    yanayun Member

    Joined:
    May 14, 2005
    Messages:
    22
    Likes Received:
    0
    Trophy Points:
    1
    updates crash

    my cpaneldnsonly problem after update to new version.
    i must reinstall os and install new cpaneldnsonly and not work.

    root@root [~]# /etc/init.d/cpanel status
    cpsrvd is stopped
    entropychat is stopped
    melange is stopped
    stunnel is stopped
    interchange is stopped

    root@root [~]# /etc/init.d/cpanel restart
    Stopping tailwatchd: 2009-01-19 09:34:50 UTC [main] Current process '1148' stopped
    [ OK ]
    Stopping cPanel services: Waiting for cpsrvd to shutdown ... ...Done
    Waiting for cpsrvd-ssl to shutdown ... ...Done
    [ OK ]
    Stopping cPanel dav services: Waiting for cpdavd to shutdown ... ...Done
    Waiting for cpdavd-ssl to shutdown ... ...Done
    [ OK ]
    Stopping cPanel brute force detector services: Waiting for cphulkd.pl to shutdown ... ...Done
    Waiting for cPhulkd to shutdown ... ...Done
    Waiting for cphulkd to shutdown ... ...Done
    [ OK ]
    Stopping pop3 services: Waiting for cppop to shutdown ... ...Done
    Waiting for cppop-ssl to shutdown ... ...Done
    [ OK ]
    Stopping cPanel log services: [FAILED]
    Stopping cPanel Chat services: [FAILED]
    Stopping Melange Chat services: [FAILED]
    Stopping InterChange services: [FAILED]
    Stopping cPanel ssl services: [ OK ]
    Stopping mailman services: [ OK ]
    Starting cPanel services: [ OK ]
    Starting cPanel brute force detector services: [ OK ]
    Starting cPanel dav services: [FAILED]
    Starting cPanel Log services: /bin/bash: /usr/local/cpanel/cpanellogd: No such file or directory
    [FAILED]
    Starting pop3 services: Waiting for cppop to shutdown ... ...Done
    Waiting for cppop-ssl to shutdown ... ...Done
    [ OK ]
    Starting cPanel Chat services:
    Starting Melange Chat services: /bin/bash: /usr/local/cpanel/bin/startmelange: No such file or directory
    [FAILED]
    Starting cPanel ssl services: Use of uninitialized value in pattern match (m//) at /usr/local/cpanel/etc/init/startstunnel line 47.
    [ OK ]
    Starting mailman services: [ OK ]
    Starting tailwatchd: [Mon Jan 19 09:34:58 2009] Starting /usr/local/cpanel/libexec/tailwatchd daemon
    Log is at /usr/local/cpanel/logs/tailwatchd_log

    root 294 0.0 0.4 2076 588 ? S<s 09:30 0:00 /sbin/udevd -d
    root 657 0.0 0.0 0 0 ? S< 09:30 0:00 [kmpathd/0]
    root 937 0.0 0.4 1652 572 ? Ss 09:30 0:00 syslogd -m 0
    root 940 0.0 0.3 1596 400 ? Ss 09:30 0:00 klogd -x
    dbus 958 0.0 0.6 2668 856 ? Ss 09:30 0:00 dbus-daemon --system
    root 995 0.0 1.0 12648 1324 ? Ssl 09:30 0:00 pcscd
    root 1043 0.0 0.7 6968 1048 ? Ss 09:30 0:00 /usr/sbin/sshd
    root 1053 0.0 0.8 5268 1108 ? Ss 09:30 0:00 crond
    xfs 1073 0.0 0.8 3224 1160 ? Ss 09:30 0:00 xfs -droppriv -daemon
    named 1218 0.0 2.4 38344 3172 ? Ssl 09:31 0:00 /usr/sbin/named -u named
    68 1296 0.0 2.4 5024 3224 ? Ss 09:31 0:00 hald
    root 1297 0.0 0.8 3060 1064 ? S 09:31 0:00 hald-runner
    root 1343 0.0 0.8 2388 1176 ? Ss 09:31 0:00 /bin/sh
    root 1344 0.0 2.1 9864 2796 ? Ss 09:33 0:00 sshd: root@pts/0
    root 1346 0.0 1.1 4464 1476 pts/0 Ss 09:33 0:00 -bash
    root 1515 0.0 2.5 5524 3400 ? Ss 09:34 0:00 tailwatchd
    cpanel 1575 0.0 0.7 5000 956 ? Ss 09:35 0:00 /usr/sbin/stunnel /usr/local/cpanel/etc/stunnel/default/stunnel.conf.run
    root 1579 0.0 0.7 4184 944 pts/0 R+ 09:38 0:00 ps aux
     
  11. henker

    henker Well-Known Member

    Joined:
    May 1, 2003
    Messages:
    60
    Likes Received:
    0
    Trophy Points:
    6
    OK, I am not out of disk space, so I can assume there is a bug in mysqlconnectioncheck ?


    Crap ! Crap !
    Code:
    /scripts/mysqlconnectioncheck
    No MySQL(R) root password set!
    Attempting to set the MySQL root user's password.
    Password Set!
    
    I never bothered to open a thread or ticket because I was always able to fix it and was too busy repairing what a simple Apache build had borked instead of complaining.
    Basically, all permissions on /home/user/www / public_html were wrong after two unsuccessful builds.

    Anyway, right now, I'm far more concerned about the next cronjob that is going to kill my setup again.
     
  12. henker

    henker Well-Known Member

    Joined:
    May 1, 2003
    Messages:
    60
    Likes Received:
    0
    Trophy Points:
    6
    Just a shot in the dark - cPanel doesn't by chance check if there is a pass="foobar" in the existing .my.cnf ?
    Because if it does, it would miss an existing password="foobar" and overwrite the .my.cnf again.
     
  13. cPanelNick

    cPanelNick Administrator
    Staff Member

    Joined:
    Mar 9, 2015
    Messages:
    3,426
    Likes Received:
    2
    Trophy Points:
    38
    cPanel Access Level:
    DataCenter Provider
    That does appear to be the problem. Since we setup the .my.cnf on server install with pass, it never checks for password. The problem is going to be unique to DNSONLY installs who have a custom mysql setup.

    Here is a simple patch to correct the problem (it will be published in the next builds)

    Code:
    Index: MysqlUtils.pm
    ===================================================================
    --- MysqlUtils.pm	(revision 33467)
    +++ MysqlUtils.pm	(revision 33468)
    @@ -49,7 +49,7 @@
         return _getmydb_param( $param, $mycnf );
     }
     
    -sub getmydbpass { return _getmydbparm( 'pass', @_ ); }
    +sub getmydbpass { return (_getmydbparm( 'pass', @_ ) || _getmydbparm( 'password', @_ )); }
     sub getmydbhost { return _getmydbparm( 'host', @_ ); }
     
     sub db_exists {
    
    If you have a ticket open the internal case # is 19514
     
  14. henker

    henker Well-Known Member

    Joined:
    May 1, 2003
    Messages:
    60
    Likes Received:
    0
    Trophy Points:
    6
    TY, appreciate it.
    For the time being, I disabled the update cron job nonetheless...
     
Loading...

Share This Page