1. Please take a little time for this simple survey! Thank you for participating!
    Dismiss Notice
  2. Dear Pleskians, please read this carefully! New attachments and other rules Thank you!
    Dismiss Notice
  3. Dear Pleskians, I really hope that you will share your opinion in this Special topic for chatter about Plesk in the Clouds. Thank you!
    Dismiss Notice

Error creating domain through CLI

Discussion in 'Plesk 10.x for Linux Issues, Fixes, How-To' started by jorfermo, Dec 15, 2010.

  1. jorfermo

    jorfermo Regular Pleskian

    26
     
    Joined:
    Jun 22, 2005
    Messages:
    102
    Likes Received:
    0
    Hi

    I'm trying to create a new domain with the CLI tools and I'm getting this error:

    Any idea why?

    Thanks
     
  2. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,572
    Likes Received:
    1,243
    Location:
    Novosibirsk, Russia
    Try to enable mysql logging and investigate SQL queries in /var/log/mysqld.log after this command.
     
  3. jorfermo

    jorfermo Regular Pleskian

    26
     
    Joined:
    Jun 22, 2005
    Messages:
    102
    Likes Received:
    0
    This is what i get:

    101216 9:10:24 76 Connect admin@localhost on
    76 Init DB psa
    76 Query SHOW VARIABLES LIKE 'version'
    76 Query select param, val from misc
    76 Query SET NAMES utf8
    77 Connect admin@localhost on psa
    77 Query SELECT 1
    77 Query SET NAMES utf8
    76 Query SELECT id FROM locales WHERE id = 'en-US'
    76 Query SELECT id FROM locales WHERE active = "true" AND id <> "en-US"
    76 Query delete from lockout where (UNIX_TIMESTAMP(NOW()) - UNIX_TIMESTAMP(last_wrong)) > (30 * 60)
    76 Init DB psa
    76 Query SHOW VARIABLES LIKE 'version'
    76 Query SET NAMES utf8
    76 Query SELECT s.sess_id, s.type, s.login_time, s.login, s.ip_address, s.click_time FROM sessions s WHERE 1 = 1
    76 Query delete from sessions where click_time < NOW() - INTERVAL 1800 SECOND
    76 Query SELECT COUNT(*) FROM clients where type <> "admin"
    76 Query SELECT * FROM clients WHERE type = 'admin'
    76 Query SELECT `param`, `val` FROM cl_param WHERE cl_id = 1
    76 Query select `id`,`name`,`place` from Skins where `id`=1
    76 Query SELECT `key`, `uid` FROM PersistentCache WHERE `events` LIKE '%api_update%'
    77 Query DESCRIBE `clients`
    77 Query SELECT `clients`.* FROM `clients` AS `clients` WHERE (`login` = 'jopontie')
    76 Query SELECT id FROM domains WHERE name='jopontie.alumnos.upv.es'
    77 Query DESCRIBE `clients`
    77 Query SELECT `clients`.* FROM `clients` AS `clients` WHERE (`id` = 1) LIMIT 1
    76 Query select `id`,`parent_id`,`vendor_id`,`type`,`cr_date`,`cname`,`pname`,`login`,`account_id`,`status`,`phone`,`fax`,`email`,`address`,`city`,`state`,`pcode`,`country`,`locale`,`limits_id`,`params_id`,`perm_id`,`pool_id`,`logo_id`,`tmpl_id`,`sapp_pool_id`,`guid`,`external_id`,`overuse` from clients where `id`=5
    76 Query select `id`,`type`,`password` from accounts where `id`=4
    76 Query SELECT id FROM domains WHERE name = "jopontie.alumnos.upv.es"
    76 Query SELECT count(*) FROM subdomains sd, domains d WHERE d.id = sd.dom_id AND CONCAT(sd.name, ".", d.name)="jopontie.alumnos.upv.es" AND sd.id !="0"
    76 Query SELECT count(*) FROM domainaliases WHERE name ="jopontie.alumnos.upv.es" AND id !="0"
    76 Query SELECT COUNT(*) FROM dns_recs WHERE type in ("CNAME", "A", "MX", "NS", "TXT") AND host="jopontie.alumnos.upv.es."
    76 Query SELECT c.pname, d.displayName, da.displayName FROM (domains d INNER JOIN clients c ON (c.id=d.cl_id)) LEFT OUTER JOIN domainaliases da ON (d.id=da.dom_id) WHERE c.id <> 5 AND (d.name IN ('alumnos.upv.es','upv.es') OR da.name IN ('alumnos.upv.es','upv.es'))
    76 Query SELECT c.pname, d.displayName, da.displayName FROM (domains d INNER JOIN clients c ON (c.id=d.cl_id)) LEFT OUTER JOIN domainaliases da ON (d.id=da.dom_id) WHERE c.id <> AND (d.name IN ('alumnos.upv.es','upv.es') OR da.name IN ('alumnos.upv.es','upv.es'))
    78 Connect pp_sb_db@localhost on sitebuilder5
    78 Query SELECT 1
    78 Query SET NAMES utf8
    78 Query SELECT `config_section`.`name` AS `section`, `config_param`.`name` AS `name`, `config_param`.`value` AS `value` FROM `config_param` AS `config_param`
    LEFT JOIN `config_section` AS `config_section` ON config_param.config_section_id = config_section.id
    76 Query delete from sessions where sess_id="9f7a00bdd584315ef000e9f9c3ee4bba"
    77 Quit
    78 Quit
    76 Quit
     
  4. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,572
    Likes Received:
    1,243
    Location:
    Novosibirsk, Russia
    I see no any inserts, updates or errors.
     
  5. jorfermo

    jorfermo Regular Pleskian

    26
     
    Joined:
    Jun 22, 2005
    Messages:
    102
    Likes Received:
    0
    The command line error doesn't read there's any insert or update.

    It could be any of these queries:

     
  6. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,572
    Likes Received:
    1,243
    Location:
    Novosibirsk, Russia
    Did you check these selects directly in psa database?
     
  7. jorfermo

    jorfermo Regular Pleskian

    26
     
    Joined:
    Jun 22, 2005
    Messages:
    102
    Likes Received:
    0
    Yes, second one raises this error:

     
  8. lhwparis

    lhwparis Guest

    0
     
    there is an integer missing for correct mysql syntax:
    after the <>
     
  9. IgorG

    IgorG Forums Analyst Staff Member

    49
    24%
    Joined:
    Oct 27, 2009
    Messages:
    24,572
    Likes Received:
    1,243
    Location:
    Novosibirsk, Russia
    Yes, the problem in "WHERE c.id <> AND (d.name IN"
    <> without parameter because:

    So, are you sure that client login 'jopontie' is really exists and associated with any cl_id? You can check it in 'clients' table.
     
  10. jorfermo

    jorfermo Regular Pleskian

    26
     
    Joined:
    Jun 22, 2005
    Messages:
    102
    Likes Received:
    0
    Sure, it exists with id=5 as you can see in the other query
     
  11. lhwparis

    lhwparis Guest

    0
     
    this querys are identical only the integer "5" is missing in second query. the question is why is this query executed twice? one time correct one time with this missing integer?
     
  12. jorfermo

    jorfermo Regular Pleskian

    26
     
    Joined:
    Jun 22, 2005
    Messages:
    102
    Likes Received:
    0
    Yes, that's the point
     
Loading...