Got an error while installing and upgrading

Traceback (most recent call last):
File “upgrade.py”, line 2888, in
main()
File “upgrade.py”, line 2884, in main
Upgrade.upgrade(args.branch)
File “upgrade.py”, line 2788, in upgrade
Upgrade.applyLoginSystemMigrations()
File “upgrade.py”, line 743, in applyLoginSystemMigrations
import sleep
ModuleNotFoundError: No module named ‘sleep’

Hi I am getting this error when it didnt work after installation then i tried to upgrade then i got this error. please help i dont want to install new os

Welcome @gaurav365, Happy to have you

  1. Which operating system are you running?

  2. Can you access the admin panel through port 8090 or whichever custom port you changed to?

  3. Run command touch /usr/local/CyberCP/debug, this will start generating more debug logs and rerun the upgrade

  4. Post the contents of /home/cyberpanel/error-logs.txt here

  5. Post the contents of /usr/local/lsws/logs/error.log here

There was no error log in /home/cyberpanel/

however the error i got while upgrading was this

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] (1045, “Access denied for user ‘cyberpanel’@‘localhost’ (u sing password: YES)”)

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] (1045, “Access denied for user ‘cyberpanel’@‘localhost’ (u sing password: YES)”)

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] (1045, “Access denied for user ‘cyberpanel’@‘localhost’ (u sing password: YES)”)

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] (1045, “Access denied for user ‘cyberpanel’@‘localhost’ (u sing password: YES)”)

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] (1045, “Access denied for user ‘cyberpanel’@‘localhost’ (u sing password: YES)”)

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] ########################################################## ###############

[10.21.2022_15-04-51] (1045, “Access denied for user ‘cyberpanel’@‘localhost’ (u sing password: YES)”)

[10.21.2022_15-04-51] ########################################################## ###############

‘int’ object has no attribute ‘execute’
Traceback (most recent call last):
File “upgrade.py”, line 740, in applyLoginSystemMigrations
cursor.execute(“UPDATE loginSystem_acl SET config = ‘%s’ where name = 'admin '” % (Upgrade.AdminACL))
AttributeError: ‘int’ object has no attribute ‘execute’

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File “upgrade.py”, line 2888, in
main()
File “upgrade.py”, line 2884, in main
Upgrade.upgrade(args.branch)
File “upgrade.py”, line 2788, in upgrade
Upgrade.applyLoginSystemMigrations()
File “upgrade.py”, line 743, in applyLoginSystemMigrations
import sleep

There was error log in this dir /usr/local/lsws/logs/error.log
[root@thehubofknowledgecom logs]# vi error.log
2022-10-20 21:45:41.582341 [INFO] [config:server:basics] httpdWorkers: 4, Num of Processors: 4
2022-10-20 21:45:41.582394 [INFO] [config:server:basics] enableLVE: 0
2022-10-20 21:45:41.582400 [INFO] [config:server:basics] bubbleWrap: 0, cmd: ‘(null)’
2022-10-20 21:45:41.582422 [NOTICE] [testAndFixDirs] “/usr/local/lsws//tmp/” exist and changed mod to 0755.
2022-10-20 21:45:41.582440 [NOTICE] [testAndFixDirs] “/usr/local/lsws//tmp/ocspcache/” exist and change own to 99:99.
2022-10-20 21:45:41.582477 [NOTICE] [testAndFixDirs] “/usr/local/lsws//conf/” own or permission need to be changed.
2022-10-20 21:45:41.598748 [INFO] [PlainConf] [httpServerConfig:] start parsing file /usr/local/lsws/conf/httpd_config.conf
2022-10-20 21:45:41.598767 [INFO] [PlainConf] [httpServerConfig:] RCS checkin config file /usr/local/lsws/conf/httpd_config.conf0 OK.
2022-10-20 21:45:41.598772 [INFO] [PlainConf] [httpServerConfig:] Finished parsing file /usr/local/lsws/conf/httpd_config.conf
2022-10-20 21:45:41.598777 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [checkprivatecache 1]
2022-10-20 21:45:41.598781 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [checkpubliccache 1]
2022-10-20 21:45:41.598786 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [maxcacheobjsize 10000000]
2022-10-20 21:45:41.598790 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [maxstaleage 200]
2022-10-20 21:45:41.598795 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [qscache 1]
2022-10-20 21:45:41.598799 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [reqcookiecache 1]
2022-10-20 21:45:41.598804 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [respcookiecache 1]
2022-10-20 21:45:41.598808 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [ignorereqcachectrl 1]
2022-10-20 21:45:41.598813 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [ignorerespcachectrl 0]
2022-10-20 21:45:41.598817 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [enablecache 0]
2022-10-20 21:45:41.598822 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [expireinseconds 3600]
2022-10-20 21:45:41.598826 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [enableprivatecache 0]
2022-10-20 21:45:41.598830 [INFO] [PlainConf] [httpServerConfig:] module [cache] add param [privateexpireinseconds 3600]
2022-10-20 21:45:41.598854 [NOTICE] Loading LiteSpeed/1.7.16 Open (lsquic 3.1.1, modgzip 1.1, cache 1.64, mod_security 1.4) BUILD (built: Mon Oct 17 21:33:28 UTC 2022) …
2022-10-20 21:45:41.598866 [NOTICE] Using [BoringSSL]
2022-10-20 21:45:41.601133 [NOTICE] [ADMIN] server socket: uds://usr/local/lsws/admin/tmp/admin.sock.7042, fd 6.
2022-10-20 21:45:41.601578 [NOTICE] [21809] chroot is disabled.
2022-10-20 21:45:41.601603 [INFO] [21809] old priority: 0, new priority: 0
2022-10-20 21:45:41.601804 [INFO] [21809] [config:server:basics2] For better obscurity, server version number is hidden in the response header.
2022-10-20 21:45:41.621033 [INFO] [21809] [PlainConf] RCS checkin config file /usr/local/lsws/conf/mime.properties0 OK.
2022-10-20 21:45:41.621254 [INFO] [21809] setuid is allowed in Ext Apps
2022-10-20 21:45:41.622052 [NOTICE] [21809] [PID: 21809]: forked cgid: 21818
2022-10-20 21:45:41.622195 [INFO] [21809] Download QUIC.cloud whitelist IP to tmp/download-quic-cloud-ips …
2022-10-20 21:45:42.545655 [INFO] [21809] Add QUIC.cloud IPs from admin/conf/quic-cloud-ips to trusted ACL …
2022-10-20 21:45:42.545735 [INFO] [21809] Add CloudFlare Subnets to trusted ACL …
2022-10-20 21:45:42.545792 [INFO] [21809] [PlainConf] [adminConfig:] start parsing file /usr/local/lsws/admin/conf/admin_config.conf
2022-10-20 21:45:42.564398 [INFO] [21809] [PlainConf] [adminConfig:] RCS checkin config file /usr/local/lsws/admin/conf/admin_config.conf0 OK.
2022-10-20 21:45:42.564445 [INFO] [21809] [PlainConf] [adminConfig:] Finished parsing file /usr/local/lsws/admin/conf/admin_config.conf
2022-10-20 21:45:42.565047 [INFO] [21809] QuicEngine::init(), pid: 21809, log level [warn].
2022-10-20 21:45:42.565747 [INFO] [21809] [Module: modcompress 1.1] has been initialized successfully
2022-10-20 21:45:42.565787 [INFO] [21809] [Module: moddecompress 1.1] has been initialized successfully
2022-10-20 21:45:42.565835 [INFO] [21809] [Module: cache 1.64] has been initialized successfully
2022-10-20 21:45:42.566301 [NOTICE] [21809] Created new Listener [adminListener].
2022-10-20 21:45:42.566334 [NOTICE] [21809] [:7080] enabled QUIC UDP
2022-10-20 21:45:42.566389 [INFO] [21809] [
:8088] Enable SO_REUSEPORT .
2022-10-20 21:45:42.566395 [NOTICE] [21809] [*:8088] Add SO_REUSEPORT socket, #1 to #4
2022-10-20 21:45:42.566448 [NOTICE] [21809] Created new Listener [Default].
2022-10-20 21:45:42.566458 [NOTICE] [21809] The maximum number of file descriptor limit is set to 50000.
2022-10-20 21:45:42.567233 [INFO] [21809] [PlainConf] [virtualHostConfig:] start parsing file /usr/local/lsws/conf/vhosts/Example/vhconf.conf
2022-10-20 21:45:42.585347 [INFO] [21809] [PlainConf] [virtualHostConfig:] RCS checkin config file /usr/local/lsws/conf/vhosts/Example/vhconf.conf0 OK.
2022-10-20 21:45:42.585391 [INFO] [21809] [PlainConf] [virtualHostConfig:] Finished parsing file /usr/local/lsws/conf/vhosts/Example/vhconf.conf
2022-10-20 21:45:42.585431 [INFO] [21809] [PlainConf] [context:/] rewrite add rules [rewritefile .htaccess]

kindly let me know what can be done.

many thanks in advance

Addressing the upgrade log:

Lookup /usr/local/CyberCP/CyberCP/settings.py where directive of

DATABASES = {
    'default': {
        'ENGINE': 'django.db.backends.mysql',
        'NAME': 'cyberpanel',
        'USER': 'cyberpanel',
        'PASSWORD': 'cyberpassword',
        'HOST': 'localhost',
        'PORT':''
    },
    'rootdb': {
        'ENGINE': 'django.db.backends.mysql',
        'NAME': 'mysql',
        'USER': 'root',
        'PASSWORD': 'rootpassword',
        'HOST': 'localhost',
        'PORT': '',
    }
}

Using the password you see under default db config try use mysql console as the user cyberpanel mysql -u cyberpanel enter the password given in /usr/local/CyberCP/CyberCP/settings.py

Traceback (most recent call last):
File “upgrade.py”, line 2888, in
main()
File “upgrade.py”, line 2884, in main
Upgrade.upgrade(args.branch)
File “upgrade.py”, line 2788, in upgrade
Upgrade.applyLoginSystemMigrations()
File “upgrade.py”, line 743, in applyLoginSystemMigrations
import sleep
ModuleNotFoundError: No module named ‘sleep’
above command failed…
[root@thehubofknowledgecom ~]# mysql --host=127.0.0.1 --port=3307 -u root -p
Enter password:
ERROR 2002 (HY000): Can’t connect to MySQL server on ‘127.0.0.1’ (115)
[root@thehubofknowledgecom ~]# mysql -u cyberpanel -p
Enter password:
ERROR 1045 (28000): Access denied for user ‘cyberpanel’@‘localhost’ (using password: YES)
[root@thehubofknowledgecom ~]#

i am not still able to make it work

Error shows you cannot connect to mysql using root or cyberpanel. Check root password here /etc/cyberpanel/mysqlPassword if you cannot access using this password then reset this password:

  1. Go to /etc/cyberpanel/mysqlPassword and change the password you see there
  2. Go to /usr/local/CyberCP/CyberCP/settings.pyand change password you see under:
    'rootdb': {
        'ENGINE': 'django.db.backends.mysql',
        'NAME': 'mysql',
        'USER': 'root',
        'PASSWORD': 'rootpassword',
        'HOST': 'localhost',
        'PORT': '',
    }
  1. Go to /home/cyberpanel/.my.cnf if said file exists and update password there.
  2. Restart LSCPD service systemctl restart lscpd

`/home/cyberpanel/.my.cnf

i tried to get to the file above but it doesnt exit and tried again

Failed to restart lscpd.service: Unit not found.
[root@thehubofknowledgecom ~]# service systemctl restart lscpd
Redirecting to /bin/systemctl restart lscpd systemctl.service
Failed to restart lscpd.service: Unit not found.
Failed to restart systemctl.service: Unit not found.
[root@thehubofknowledgecom ~]#

i want to address the cyberpanel installation wasnt completely done so i tried to upgrade to finish. but now i am getting errors

Oh ! You will need to rollback your server to a later date before installing CyberP. If your hosting service does not offer such a service then reinstall your server operating system. Then install a fresh copy of CyberP.

This is because we cannot do anything about unfinished installation of CyberP. Trying to upgrade it won’t work.

This topic was automatically closed 3 hours after the last reply. New replies are no longer allowed.