Ошибки scj update TCMS

support@serverel.com
Posts: 87
Joined: Wed Aug 24, 2016 1:27 pm

Ошибки scj update TCMS

Post by support@serverel.com »

Здравствуйте.
Пытаем обновится с scj до TCMS. Однако получаем ошибки:

Code: Select all

cd /home/sites/sites/SITE.com/boy2/bin; env HTTP_HOST=SITE.com /usr/bin/php -q cron.php
PHP Fatal error:  Uncaught exception 'Exception' with message 'Mysql error:: 1146 (Table 'tcms_SITE_com.trader_group_urls' doesn't exist) (d$
Stack trace:
#0 /home/sites/sites/SITE.com/boy2/includes/db_modules/mysql.php(160): db_error('SELECT * FROM t...', 1146, 'Table 'tcms_boy...', 'db_link')
#1 /home/sites/sites/SITE.com/boy2/includes/db_modules/mysql.php(301): db_query('SELECT * FROM t...', 'db_link')
#2 /home/sites/sites/SITE.com/boy2/includes/libs/trader_thumbs.php(0): db_get_all()
#3 /home/sites/sites/SITE.com/boy2/bin/cron.php(0): make_trader_thumbs()
#4 /home/sites/sites/SITE.com/boy2/bin/cron.php(0): ext_stats()
#5 {main}
  thrown in /home/sites/sites/SITE.com/boy2/includes/db_modules/mysql.php on line 129

Fatal error: Uncaught exception 'Exception' with message 'Mysql error:: 1146 (Table 'tcms_SITE_com.trader_group_urls' doesn't exist) (db_lin$
Stack trace:
#0 /home/sites/sites/SITE.com/boy2/includes/db_modules/mysql.php(160): db_error('SELECT * FROM t...', 1146, 'Table 'tcms_boy...', 'db_link')
#1 /home/sites/sites/SITE.com/boy2/includes/db_modules/mysql.php(301): db_query('SELECT * FROM t...', 'db_link')
#2 /home/sites/sites/SITE.com/boy2/includes/libs/trader_thumbs.php(0): db_get_all()
#3 /home/sites/sites/SITE.com/boy2/bin/cron.php(0): make_trader_thumbs()
#4 /home/sites/sites/SITE.com/boy2/bin/cron.php(0): ext_stats()
#5 {main}
  thrown in /home/sites/sites/SITE.com/boy2/includes/db_modules/mysql.php on line 129

Старую версию апдейтим, базу конвертируем, файлы рода common.php редактируем до необходимых. И всё равно при запуске кроны получаем ошибки и сайт не отображается верно.

Полный лог операций примерно такой:

Code: Select all

root@s3636:/home/sites/sites/SITE.RU# nano /root/myisam_to_innidb.sh
root@s3636:/home/sites/sites/SITE.RU# /root/./myisam_to_innidb.sh
Converting tables for database scj_SITE_com
mysql: [Warning] Using a password on the command line interface can be insecure.
  Alter table table admin_sessions ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table blacklist ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table bookmarks ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table browsers ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table countries ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table day ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table day_last_hour ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table forces ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table functions_data ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table ga_categories ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table ga_sites ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table history ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table inrules ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table ips ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table ips_history ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table language ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table links ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table out_ips ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table out_ips2trader ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table outrules ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table quality_settings ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table refs ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table skim_rules ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table tds_rules ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table tds_schemes ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
  Alter table table trader_plugs ... mysql: [Warning] Using a password on the command line interface can be insecure.
done
Converting completed
root@s3636:/home/sites/sites/SITE.RU# 
root@s3636:/home/sites/sites/SITE.RU/boy/admin# env HTTP_HOST=gayteenshd.com php update.php 52
Processing 52 for domain gayteenshd.com
Update 52. 
**Update 52**

    Please, Take a look at wiki for comments.
    http://smartcj.com/wiki/doku.php?id=update_52

Please, DO NOT run updates using root account. Update WAS NOT processed.root@s3636:/home/sites/sites/SITE.RU/boy/admin# 
root@s3636:/home/sites/sites/SITE.RU/boy/admin# su sites
[ 0  3.1ms ] 00:32:43 sites@s3636:~/sites/SITE.RU/boy/admin$ env HTTP_HOST=gayteenshd.com php update.php 52
Processing 52 for domain gayteenshd.com
Update 52. 
**Update 52**

    Please, Take a look at wiki for comments.
    http://smartcj.com/wiki/doku.php?id=update_52

Checking indexes rot_gal2tag 
Checking indexes rot_gal2tag1 
Checking indexes rot_gal2tag2 
Checking indexes rot_gal2tag3 
Compressing thumb urls .. 
Downloading files 
100% downloaded  Done, everything's ok

    Admin area modifications - done 

    New out.php, please, copy from scj/cgi to your location (usually root of domain)

    </b>
    Done. <b>Please, read this.

    Note, scj/cgi/index.php and scj/cgi/out.php are updated, if you use it at the root of your domain - copy please.

    **Update 52**
    Please, Take a look at wiki for comments.
    http://smartcj.com/wiki/doku.php?id=update_52

    Note !!! index.php and out.php are updated. If you use it outside scj/cgi folder - copy it to your location.
    Please, read wiki for comments.

[ 0  4.460s ] 00:32:51 sites@s3636:~/sites/SITE.RU/boy/admin$ exit
root@s3636:/home/sites/sites/SITE.RU/boy/admin# cd ..\..
bash: cd: ....: No such file or directory
root@s3636:/home/sites/sites/SITE.RU/boy/admin# cd ../..
root@s3636:/home/sites/sites/SITE.RU# curl -sS http://smartcj.com/updates2/install | php --
Folder name for script (default is scj): boy2

Type your domain (only domain ie site.com  - NO WWW, NO HTTP) : SITE.RU

Type your email (will be used as script admin email) : admin@SITE.RU

Downloading script files 
100% downloaded  
 Done 
Making config.php 
Mysql host (usually localhost): localhost

Mysql username: SITE_com

Mysql password: YSRKMgwIxZlAkwY

Mysql DB name: scj_SITE_com2

mysql: [Warning] Using a password on the command line interface can be insecure.
Add following to Crontab (note, if you are not going to use internal rotation you can skip line with rot.php) 

#SmartCJ Pro at domain SITE.RU
*/1 * * * * cd /home/sites/sites/SITE.RU/boy2/bin; env HTTP_HOST=SITE.RU /usr/bin/php -q cron.php 
*/1 * * * * cd /home/sites/sites/SITE.RU/boy2/bin; env HTTP_HOST=SITE.RU /usr/bin/php -q rotation.php 

 Script Installation is done. Please, open http://SITE.RU/boy2/admin/ in your browser. Your login is 'admin' and password is 'ebarfxpqqj'. 

sendmail: RCPT TO:<admin@SITE.RU> (550 5.1.1  https://support.google.com/mail/?p=NoSuchUser e4-v6si12607609plk.263 - gsmtp)
Done, everything's ok                                                                          

root@s3636:/home/sites/sites/SITE.RU# cd boy2/bin/
root@s3636:/home/sites/sites/SITE.RU/boy2/bin# php scj_1to2_db_converter.php
SCJ v1 Host: localhost

SCJ v1 Username: SITE_com

SCJ v1 Password: YSRKMgwIxZlAkwY

SCJ v1 DB name: scj_SITE_com2

Type 'md5' if you want gallery slugs to be gallery_md5 or just hit enter 

Copy traders (77.109224081039, 77.109224081039) 
Coping table admins (77.140467166901, 0.031243085861206) 
Coping table admin_access_log (77.142455101013, 0.0019879341125488) 
Coping table admin_sessions (77.144892215729, 0.0024371147155762) 
Coping table blacklist (77.148432016373, 0.0035398006439209) 
Coping table browsers (77.151755094528, 0.0033230781555176) 
Coping table forces (77.154194116592, 0.002439022064209) 
Coping table functions_data (77.156352996826, 0.0021588802337646) 
Coping table ga_categories (77.158203125, 0.0018501281738281) 
Coping table ga_sites (77.160459041595, 0.002255916595459) 
Coping table inrules (77.162425994873, 0.0019669532775879) 
Coping table ips (77.164335012436, 0.0019090175628662) 
Coping table language (77.166100025177, 0.0017650127410889) 
Coping table links (77.168129205704, 0.0020291805267334) 
Coping table outrules (77.170264005661, 0.0021347999572754) 
Coping table out_ips (77.172274112701, 0.0020101070404053) 
Coping table out_ips2trader (77.174094200134, 0.0018200874328613) 
Coping table quality_settings (77.177276134491, 0.0031819343566895) 
Coping table refs (77.179156064987, 0.0018799304962158) 
Coping table reports (77.180771112442, 0.001615047454834) 
Coping table rot_cell_data (77.182411193848, 0.0016400814056396) 
Coping table rot_cell_skimming (77.189090013504, 0.0066788196563721) 
Coping table rot_groups (77.190786123276, 0.0016961097717285) 
Coping table rot_groups_data (77.192748069763, 0.0019619464874268) 
Coping table rot_models (77.194579124451, 0.0018310546875) 
Coping table rot_models_data (77.196432113647, 0.0018529891967773) 
Coping table rot_sponsors (77.198055028915, 0.0016229152679443) 
Coping table rot_sponsors_data (77.199796199799, 0.0017411708831787) 
Coping table rot_crop_profiles (77.201471090317, 0.0016748905181885) 
Coping table rot_pages (77.203569173813, 0.0020980834960938) 
Coping table rot_replacements (77.205488204956, 0.0019190311431885) 
Coping table rot_import_sets (77.20706820488, 0.0015799999237061) 
Coping table rot_search_queries (77.208700180054, 0.0016319751739502) 
Coping table rot_servers (77.210436105728, 0.0017359256744385) 
Coping table rot_users (77.212133169174, 0.0016970634460449) 
Coping table skim_rules (77.213936090469, 0.001802921295166) 
Coping table tds_rules (77.215715169907, 0.0017790794372559) 
Coping table tds_schemes (77.217594146729, 0.0018789768218994) 
Coping table toplists (77.219170093536, 0.0015759468078613) 
Coping table trader_groups (77.220795154572, 0.0016250610351562) 
Mysql error 1054: Unknown column 'rot_user_fav.gallery_md5' in 'on clause'  (Please, run update. If it doesnt help - contact script support)  (77.223771095276, 0.0029759407043457) 
PHP Fatal error:  Uncaught exception 'Exception' with message 'Mysql error:: 1054 (Unknown column 'rot_user_fav.gallery_md5' in 'on clause') (scj_51) in query SELECT user_id, source_url FROM rot_user_fav
       LEFT JOIN rot_gallery_info ON rot_user_fav.gallery_md5 = rot_gallery_info.gallery_md5 . () ' in /home/sites/sites/SITE.RU/boy2/includes/db_modules/mysql.php:129
Stack trace:
#0 /home/sites/sites/SITE.RU/boy2/includes/db_modules/mysql.php(160): db_error('SELECT user_id,...', 1054, 'Unknown column ...', 'scj_51')
#1 /home/sites/sites/SITE.RU/boy2/bin/scj_1to2_db_converter.php(0): db_query()
#2 {main}
  thrown in /home/sites/sites/SITE.RU/boy2/includes/db_modules/mysql.php on line 129

Fatal error: Uncaught exception 'Exception' with message 'Mysql error:: 1054 (Unknown column 'rot_user_fav.gallery_md5' in 'on clause') (scj_51) in query SELECT user_id, source_url FROM rot_user_fav
       LEFT JOIN rot_gallery_info ON rot_user_fav.gallery_md5 = rot_gallery_info.gallery_md5 . () ' in /home/sites/sites/SITE.RU/boy2/includes/db_modules/mysql.php:129
Stack trace:
#0 /home/sites/sites/SITE.RU/boy2/includes/db_modules/mysql.php(160): db_error('SELECT user_id,...', 1054, 'Unknown column ...', 'scj_51')
#1 /home/sites/sites/SITE.RU/boy2/bin/scj_1to2_db_converter.php(0): db_query()
#2 {main}
  thrown in /home/sites/sites/SITE.RU/boy2/includes/db_modules/mysql.php on line 129

Не могли бы Вы помочь ?
admin
Site Admin
Posts: 37242
Joined: Wed Sep 10, 2008 11:43 am

Re: Ошибки scj update TCMS

Post by admin »

Приветствую!

судя по логу вы ставите версию 2 сразу в базу версии 1 и она там переписывает таблицы

надо

1. поставить версию 2 в новую базу не трогая старую базу
2. запустить конверт
Don't forget to run script update
support@serverel.com
Posts: 87
Joined: Wed Aug 24, 2016 1:27 pm

Re: Ошибки scj update TCMS

Post by support@serverel.com »

Здравствуйте.
Для второй версии у нас отдельная новая база создаётся и уже потом запускается скрипт для подтягивания данных с первой версии.
admin
Site Admin
Posts: 37242
Joined: Wed Sep 10, 2008 11:43 am

Re: Ошибки scj update TCMS

Post by admin »

точно повторяется проблема?
тогда скидывайте шел и данные куда ставить 2. версию что б повторить проблему
Don't forget to run script update
support@serverel.com
Posts: 87
Joined: Wed Aug 24, 2016 1:27 pm

Re: Ошибки scj update TCMS

Post by support@serverel.com »

admin wrote: Mon Nov 12, 2018 5:46 am Приветствую!

судя по логу вы ставите версию 2 сразу в базу версии 1 и она там переписывает таблицы

надо

1. поставить версию 2 в новую базу не трогая старую базу
2. запустить конверт
Последовательность действий у нас следующая:
1. Переводим все таблицы базы в innodb скриптом

Code: Select all

/root/./myisam_to_innidb.sh
2. Ставим апдэйт до 5.2
[codeenv HTTP_HOST=site.com php update.php 52
Processing 52 for domain site.com
Update 52.
**Update 52**

Please, Take a look at wiki for comments.
http://smartcj.com/wiki/doku.php?id=update_52

Checking indexes rot_gal2tag
Checking indexes rot_gal2tag1
Checking indexes rot_gal2tag2
Checking indexes rot_gal2tag3
Checking indexes rot_gal2tag5
Checking indexes rot_gal2tag8
Compressing thumb urls ..
Downloading files
100% downloaded Done, everything's ok

Admin area modifications - done

New out.php, please, copy from scj/cgi to your location (usually root of domain)

</b>
Done. <b>Please, read this.

Note, scj/cgi/index.php and scj/cgi/out.php are updated, if you use it at the root of your domain - copy please.

**Update 52**
Please, Take a look at wiki for comments.
http://smartcj.com/wiki/doku.php?id=update_52

Note !!! index.php and out.php are updated. If you use it outside scj/cgi folder - copy it to your location.
Please, read wiki for comments.
[/code]
3. устанавливаем 2-ю версию, вводим данные к созданной базе

Code: Select all

 Script Installation is done. Please, open http://site.com/cms2/admin/ in your browser. Your login is 'admin' and password is 'zcnsptyurs'. 

sendmail: 550 5.7.1  for more information. n11-v6si25303293plg.300 - gsmtp
Done, everything's ok
4. Запускаем конвертер scj_1to2_db_converter.php
тут получаем ошибки

Code: Select all

#0 /home/sites/sites/site.com/cms2/includes/db_modules/mysql.php(160): db_error('SELECT gallery_...', 1064, 'You have an err...', 'db_link')
#1 /home/sites/site.com/cms2/includes/db_modules/mysql.php(267): db_query('SELECT gallery_...', 'db_link')
#2 /home/sites/sites.com/cms2/bin/scj_1to2_db_converter.php(0): db_val()
#3 {main}
  thrown in /home/sites/sites.com/cms2/includes/db_modules/mysql.php on line 129
стоит заметить что такое происходит не для всех баз, на некоторых доменах всё отрабатывает без ошибок, но но появляются уже ошибки непосредственно в админке, в частности при редактировании галерей

Code: Select all

1) Не отображается информация по галереям

http://site.com/cms2/admin/?operation=rotation&sub=rot_list&vars[status][]=active&vars[show_linked_site_id]=1&vars[export_limit]=1000&vars[export_delimiter]=|&vars[pattern][]=url&vars[pattern][]=desc&vars[pattern][]=thumb&vars[pattern][]=skip&vars[pattern][]=skip&vars[pattern][]=skip&vars[pattern][]=skip&vars[pattern][]=skip&vars[pattern][]=skip&vars[export_fields_num]=9&vars[sort]=total_ctr%20desc&vars[layout]=full&vars[results_per_page]=18&vars[rows_per_page]=5&vars[cols_per_page]=3&vars[show_thumbs]=0&vars[site_id]=1&vars[description_id]=1&page=0

Нажимаем Edit Item ( http://site.com/cms2/admin/?operation=rot_edit&redir=true&gallery_id=21161 )

Получаем ошибку для всех видео

Fatal error: Uncaught exception 'Exception' with message 'Mysql error:: 1054 (Unknown column 't.tag_name15' in 'field list') (db_link) in query SELECT gallery_id, t.tag_name15 as tag_name FROM rot_gal2tag as g2t LEFT JOIN rot_tags AS t on t.tag_id = g2t.tag_id WHERE gallery_id IN ('21161') AND site_id = '15' . (site.com) ' in /home/sites/sites/site.com/cms2/includes/db_modules/mysql.php:129 Stack trace: #0 /home/sites/sites/site.com/cms2/includes/db_modules/mysql.php(160): db_error('SELECT gallery_...', 1054, 'Unknown column ...', 'db_link') #1 /home/sites/sites/site.com/cms2/includes/libs/tpl_functions.php(0): db_query() #2 /home/sites/sites/site.com/cms2/includes/libs/rot_functions.php(0): gallery_get_tags() #3 /home/sites/sites/site.com/cms2/admin/files/rot_edit.php(0): gallery_load() #4 /home/sites/sites/site.com/cms2/admin/index.php(0): unknown() #5 {main} thrown in /home/sites/sites/site.com/cms2/includes/db_modules/mysql.php on line 129
С чем может быть связаны оба этих вопроса.
Спасибо
admin
Site Admin
Posts: 37242
Joined: Wed Sep 10, 2008 11:43 am

Re: Ошибки scj update TCMS

Post by admin »

те на какой-то из баз есть ошибка при конвертации

как и писал выше - или шел или сама база на котрой можно тестировать

иначе заниматься размышлениями "а что бы это молго быть" можно очнеь долго
Don't forget to run script update
support@serverel.com
Posts: 87
Joined: Wed Aug 24, 2016 1:27 pm

Re: Ошибки scj update TCMS

Post by support@serverel.com »

Нам необходимо время для принятия решения дальнейших действий.
admin
Site Admin
Posts: 37242
Joined: Wed Sep 10, 2008 11:43 am

Re: Ошибки scj update TCMS

Post by admin »

Хорошо
Don't forget to run script update
support@serverel.com
Posts: 87
Joined: Wed Aug 24, 2016 1:27 pm

Re: Ошибки scj update TCMS

Post by support@serverel.com »

Здравствуйте. Базу, с которой возникают проблемы, можете скачать по ссылке:

Ждем от Вас ответа.
admin
Site Admin
Posts: 37242
Joined: Wed Sep 10, 2008 11:43 am

Re: Ошибки scj update TCMS

Post by admin »

Я сомневаюсь что вы запускаете на этой базе конверт
там в этой базе вообще 0 записей в таблице ротации
Don't forget to run script update
Post Reply