[mythtv-users] db restore

Daryl McDonald darylangela at gmail.com
Sun Aug 5 14:48:01 UTC 2018


On Sun, Aug 5, 2018 at 10:19 AM, Jay Harbeston (ISeePeople) <
jharbestonus at gmail.com> wrote:

>
>
> On Aug 5, 2018, at 10:03 AM, Daryl McDonald <darylangela at gmail.com> wrote:
>
> Greetings Mythizens, I've rebuilt after a drive failure, and I'm having
> trouble restoring the database. I downloaded the back-up and restore files
>
> daryl at trieli:~$ chmod a+x mythconverg_backup.pl mythconverg_restore.pl
> daryl at trieli:~$ mythconverg_restore.pl --drop_database --create_database
> --filename mythconverg-1344-20180804112717.sql.gz
> mythconverg_restore.pl: command not found
> daryl at trieli:~$ mythconverg_restore.pl --directory/home/daryl
> --drop_database --create_database --filename mythconverg-1344-
> 20180804112717.sql.gz
> mythconverg_restore.pl: command not found
> daryl at trieli:~$ cd /home/dary/
> bash: cd: /home/dary/: No such file or directory
> daryl at trieli:~$ cd Home
> bash: cd: Home: No such file or directory
> daryl at trieli:~$ ls -al
> total 52180
> drwxr-xr-x 18 daryl daryl     4096 Aug  5 09:40 .
> drwxr-xr-x  4 root  root      4096 Aug  5 09:21 ..
> -rw-------  1 daryl daryl      146 Aug  5 08:37 .bash_history
> -rw-r--r--  1 daryl daryl      220 Aug  5 07:36 .bash_logout
> -rw-r--r--  1 daryl daryl     3771 Aug  5 07:36 .bashrc
> drwx------ 18 daryl daryl     4096 Aug  5 08:39 .cache
> drwx------ 16 daryl daryl     4096 Aug  5 08:50 .config
> drwxr-xr-x  2 daryl daryl     4096 Aug  5 07:59 Desktop
> drwxr-xr-x  2 daryl daryl     4096 Aug  5 07:59 Documents
> drwxr-xr-x  2 daryl daryl     4096 Aug  5 08:50 Downloads
> -rw-r--r--  1 daryl daryl     8980 Aug  5 07:36 examples.desktop
> drwx------  2 daryl daryl     4096 Aug  5 08:27 .gconf
> drwx------  3 daryl daryl     4096 Aug  5 08:32 .gnupg
> -rw-------  1 daryl daryl      636 Aug  5 08:32 .ICEauthority
> drwxr-xr-x  7 daryl daryl     4096 Aug  5 08:51 .kodi
> drwx------  3 daryl daryl     4096 Aug  5 07:59 .local
> drwx------  5 daryl daryl     4096 Aug  5 08:33 .mozilla
> drwxr-xr-x  2 daryl daryl     4096 Aug  5 07:59 Music
> -rw-r--r--  1 daryl daryl 53170263 Aug  4 11:27 mythconverg-1344-
> 20180804112717.sql.gz
> -rwxrwxr-x  1 daryl daryl    59103 Aug  5 09:39 mythconverg_backup.pl
> -rwxrwxr-x  1 daryl daryl    68814 Aug  5 09:40 mythconverg_restore.pl
> drwxr-xr-x  2 daryl daryl     4096 Aug  5 07:59 Pictures
> drwx------  3 daryl daryl     4096 Aug  5 08:39 .pki
> -rw-r--r--  1 daryl daryl      675 Aug  5 07:36 .profile
> drwxr-xr-x  2 daryl daryl     4096 Aug  5 07:59 Public
> -rwxrwxr-x  1 daryl daryl     1107 Oct 23  2014 shortlog.sh
> -rw-r--r--  1 daryl daryl        0 Aug  5 08:01 .sudo_as_admin_successful
> drwxr-xr-x  2 daryl daryl     4096 Aug  5 07:59 Templates
> drwxr-xr-x  2 daryl daryl     4096 Aug  5 07:59 Videos
> -rwxrwxr-x  1 daryl daryl      555 Sep 24  2016 wakeup_test.sh
> -rw-------  1 daryl daryl       51 Aug  5 08:31 .Xauthority
> -rw-------  1 daryl daryl       82 Aug  5 08:31 .xsession-errors
> -rw-------  1 daryl daryl     1228 Aug  5 08:31 .xsession-errors.old
>
>
> You can run this by doing perl mythconverg………
>
>  the ‘errors’  you are seeing is that your home directory is NOT in your
> path.  The rest of the commands look fine.
>
>
>
>
> daryl at trieli:~$ mythconverg_restore.pl --drop_database --create_database
> --filename mythconverg-1344-20180804112717.sql.gz
> mythconverg_restore.pl: command not found
> daryl at trieli:~$ ./mythconverg_restore.pl --drop_database
> --create_database --filename mythconverg-1344-20180804112717.sql.gz
>
> ERROR: DBBackupDirectory not specified, stopped at ./
> mythconverg_restore.pl line 773.
> daryl at trieli:~$ ./mythconverg_restore.pl --drop_database
> --create_database --directory ~ --filename mythconverg-1344-
> 20180804112717.sql.gz
> DBI connect('host=:database=mythconverg','',...) failed: Access denied
> for user 'daryl'@'localhost' (using password: NO) at ./
> mythconverg_restore.pl line 933.
> DBI connect('host=','',...) failed: Access denied for user 'daryl'@'localhost'
> (using password: NO) at ./mythconverg_restore.pl line 933.
>
> Unable to connect to database.
>            database: mythconverg
>                host:
>            username:
> To see the password used, please re-run the script with the --verbose
> argument.
>
> Please check your configuration files to verify the database connection
> information is correct.  The files that are used to retrieve connection
> information are prefixed with "parsing" in the "Parsing configuration
> files"
> section of the --verbose output.
>
> Also note that any [client] or [mysql] password specified in the MySQL
> options
> file (/etc/my.cnf or /etc/mysql/my.cnf or ~/.my.cnf) will take precedence
> over
> the password specified in the MythTV configuration files.
>
> ERROR: Unable to connect to database.
>
> I would appreciate any help getting this fixed. Daryl
>
>
I'm still getting nowhere:
 daryl at trieli:~$ ./mythconverg_restore.pl --create_database --directory ~
--filename mythconverg-1344-20180804112717.sql.gz --verbose

Configuring environment:
  -    username: daryl
  -        HOME: /home/daryl
  - MYTHCONFDIR: /home/daryl/.mythtv

Parsing configuration files:
  - checking: /home/daryl/.mythtv/config.xml
  - checking: /usr/local/share/mythtv/mysql.txt
  - checking: /usr/share/mythtv/mysql.txt
  - checking: /usr/local/etc/mythtv/mysql.txt
  - checking: /etc/mythtv/mysql.txt
  - checking: /home/daryl/.mythtv/mysql.txt
  - checking: mysql.txt
  - checking: /home/daryl/.mythtv/mysql.txt
  - checking: /home/daryl/.mythtv/backuprc

Applying command-line arguments.

Checking configuration.

WARNING: DBName not specified. Using mythconverg

WARNING: DBHostName not specified.
         Assuming it is specified in the MySQL options file.

WARNING: DBUserName not specified.
         Assuming it is specified in the MySQL options file.

WARNING: DBPassword not specified.
         Assuming it is specified in the MySQL options file.

Database Information:
         DBHostName:
             DBPort: -1
         DBUserName:
         DBPassword:
             DBName: mythconverg
        DBSchemaVer:
  DBBackupDirectory: /home/daryl
   DBBackupFilename: mythconverg-1344-20180804112717.sql.gz
      drop_database: no
    create_database: yes

Executables:
       mysql_client: mysql
         uncompress: gzip -d

Miscellaneous:
    partial_restore: no
   restore_xmltvids: no
    change_hostname: no

Checking database.
DBI connect('host=:database=mythconverg','',...) failed: Access denied for
user 'daryl'@'localhost' (using password: NO) at ./mythconverg_restore.pl
line 933.

Preparing initial database.
DBI connect('host=','',...) failed: Access denied for user 'daryl'@'localhost'
(using password: NO) at ./mythconverg_restore.pl line 933.

Unable to connect to database.
           database: mythconverg
               host:
           username:
           password:

Please check your configuration files to verify the database connection
information is correct.  The files that are used to retrieve connection
information are prefixed with "parsing" in the "Parsing configuration files"
section of the --verbose output.

Also note that any [client] or [mysql] password specified in the MySQL
options
file (/etc/my.cnf or /etc/mysql/my.cnf or ~/.my.cnf) will take precedence
over
the password specified in the MythTV configuration files.

ERROR: Unable to connect to database.

_______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://lists.mythtv.org/mailman/listinfo/mythtv-users
> http://wiki.mythtv.org/Mailing_List_etiquette
> MythTV Forums: https://forum.mythtv.org
>
>
>
> _______________________________________________
> mythtv-users mailing list
> mythtv-users at mythtv.org
> http://lists.mythtv.org/mailman/listinfo/mythtv-users
> http://wiki.mythtv.org/Mailing_List_etiquette
> MythTV Forums: https://forum.mythtv.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.mythtv.org/pipermail/mythtv-users/attachments/20180805/9256901b/attachment.html>


More information about the mythtv-users mailing list