CQRlog 2.4.0-3

14 posts / 0 new
Last post
K5LY
K5LY's picture
CQRlog 2.4.0-3

Ubuntu did a partial-upgrade to Ubuntu Focal Fossa (development branch)
The following CQRlog applications were installed.
CQRLOG - 2.4.0-3
CQRLOG-DATA - 2.4.0-3

Now my CQRlog does not open, believe it to be unstable.

I cannot remove the applications - because says installation must be reinstalled.
When attempt to reinstall - does not complete because of error.

When attempting to update ppa from: "http://ppa.launchpad.net/ok2cqr/ppa/ubuntu focal main"

Receive the following error.

"E: The repository 'http://ppa.launchpad.net/ok2cqr/ppa/ubuntu focal Release' does not have a Release file.
N: Updating from such a repository can't be done securely, and is therefore disabled by default."

How can I remove, or repair my CQRlog installation?

oh1kh
CQRlog 2.4.0-3

Hi !

Your logs are in ~/.config/cqrlog folder. Copy all files and subfolders to backup everything.
cqrlog binary is usually in /usr/bin/cqrlog (may also be in /usr/local/bin/cqrlog)
Other cqrlog stuff is usually under /usr/share/cqrlog folder.

Removing them removes cqrlog. But if you have installed via package manager it still thinks cqrlog is installed you have to clean managers database too. Also startup menus may stay showing cqrlog that does not exist.

That is normally done with 'uninstall' or 'remove' packet manager command option.
Why can't you do that?

There is also a command (with Fedora it is 'rpm -ql' that sows what is inside a packet.
In case of Fedora I would do:
rpm -ql CQRLOG - 2.4.0-3
rpm -ql CQRLOG-DATA - 2.4.0-3
To see what files have been installed (and then maybe manually remove them).

With Ubuntu this command might be dpkg with some option parameter. I do not know for sure.

It would be interesting to know what text you get now when trying to start cqrlog from console with command:

cqrlog debug=1

Maybe there is just a small problem.

--
Saku
OH1KH

K5LY
K5LY's picture
Saku thanks, I will attempt

Saku thanks, I will attempt your suggestions.

73,

K5LY
New Hope, TX
CW Forever

K5LY
K5LY's picture
Saku, I have backedup up /

Saku, I have backedup up /.config/cqrlog folder
and removed /usr/share/cqrlog folder

Cqrlog binary was not located in /usr/bin/cqrlog or /usr/local/cqrlog

cqrlog debug=1 Results are - command 'cqrlog' not found, but can be installed with: sudo apt-get cqrlog

cqrlog - continues to display in Synaptic Manager: CQRLOG and CQRLOG-DATA
Attempted to remove with: Mark for complete removal
Results - error in package cqrlog
E: cqrlog package is in a very bad inconsistent state; you should reinstall it before attempting a removal

Is there a list/file somewhere which continues to indicate that cqrlog is installed?

Thanks,

K5LY
New Hope, TX
CW Forever

DL2KI
Hi K5LY,

Hi K5LY,

the command for Ubuntu is:

dpkg -l cqrlog and / or
dpkg -L cqrlog

73, Wolfgang
DL2KI

K5LY
K5LY's picture
Wolfgang, thanks for the info

Wolfgang, thanks for the info.

73,

K5LY
New Hope, TX
CW Forever

DL2KI
Hi K5LY,

Hi K5LY,

if you remove the files manually from the filesystem, they will still be registered in the Debian package database. So you have to force the removal with dpkg.

You could try this command in the console:
"dpkg --purge --force-all cqrlog"

73, Wolfgang
DL2KI

K5LY
K5LY's picture
Hello Wolfgang,

Hello Wolfgang,

I have previously tried sudo dpkg --purge --force-all cqrlog
and receive the following error message.

lee@lee-desktop:~$ sudo dpkg --purge --force-all cqrlog
[sudo] password for lee:
dpkg: warning: overriding problem because --force enabled:
dpkg: warning: package is in a very bad inconsistent state; you should
reinstall it before attempting a removal
(Reading database ... 275492 files and directories currently installed.)
Removing cqrlog (2.4.0-3) ...

Changes removed from /etc/apparmor.d/local/usr.sbin.mysqld
Restarting apparmor...

Job for apparmor.service failed because the control process exited with error code.
See "systemctl status apparmor.service" and "journalctl -xe" for details.
invoke-rc.d: initscript apparmor, action "restart" failed.
‚óŹ apparmor.service - Load AppArmor profiles
Loaded: loaded (/lib/systemd/system/apparmor.service; enabled; vendor preset: enabled)
Active: failed (Result: exit-code) since Wed 2020-01-22 13:19:15 CST; 5ms ago
Docs: man:apparmor(7)
https://gitlab.com/apparmor/apparmor/wikis/home/
Process: 10597 ExecStart=/lib/apparmor/apparmor.systemd reload (code=exited, status=1/FAILURE)
Main PID: 10597 (code=exited, status=1/FAILURE)

Jan 22 13:19:15 lee-desktop apparmor.systemd[10628]: Skipping profile in /etc/apparmor.d/disable: usr.bin.firefox
Jan 22 13:19:15 lee-desktop apparmor.systemd[10633]: Skipping profile in /etc/apparmor.d/disable: usr.sbin.rsyslogd
Jan 22 13:19:15 lee-desktop apparmor.systemd[10640]: AppArmor parser error for /etc/apparmor.d in /etc/apparmor.d/usr.sbin.mysqld at line 15: syntax error, unexpected TOK_CLOSE, expecting $end
Jan 22 13:19:15 lee-desktop apparmor.systemd[10688]: Skipping profile in /etc/apparmor.d/disable: usr.bin.firefox
Jan 22 13:19:15 lee-desktop apparmor.systemd[10729]: AppArmor parser error for /etc/apparmor.d/usr.sbin.mysqld in /etc/apparmor.d/usr.sbin.mysqld at line 15: syntax error, unexpected TOK_CLOSE, expecting $end
Jan 22 13:19:15 lee-desktop apparmor.systemd[10736]: Skipping profile in /etc/apparmor.d/disable: usr.sbin.rsyslogd
Jan 22 13:19:15 lee-desktop apparmor.systemd[10597]: Error: At least one profile failed to load
Jan 22 13:19:15 lee-desktop systemd[1]: apparmor.service: Main process exited, code=exited, status=1/FAILURE
Jan 22 13:19:15 lee-desktop systemd[1]: apparmor.service: Failed with result 'exit-code'.
Jan 22 13:19:15 lee-desktop systemd[1]: Failed to start Load AppArmor profiles.
dpkg: error processing package cqrlog (--purge):
installed cqrlog package post-removal script subprocess returned error exit status 1
Errors were encountered while processing:
cqrlog
lee@lee-desktop:~$

Wondering if I should first remove mysql?

K5LY
New Hope, TX
CW Forever

K5LY
K5LY's picture
Using Synaptic reinstalled

Using Synaptic reinstalled mysql, then installed cqrlog 2.4.0-3.
Copied backed up cqrlog files into /.config/cqrlog

cqrlog does connect to mysql server

Using debug mode:
lee@lee-desktop:~$ cqrlog -debug

Cqrlog Ver:2.4.0 (001) Date:2019-10-27
**** DEBUG LEVEL 1 ****

OS:
Linux version 5.4.0-9-generic (buildd@lcy01-amd64-023) (gcc version 9.2.1 20191130 (Ubuntu 9.2.1-21ubuntu1)) #12-Ubuntu SMP Mon Dec 16 22:34:19 UTC 2019
SSL libraries:
libssl.so
libcrypto.so
Loaded 137314 LoTW users
Loaded 127581 eQSL users
Loaded 35084 SCP calls
*
User home directory: /home/lee/
Program home directory: /home/lee/.config/cqrlog/
Data directory: /home/lee/.config/cqrlog/database/
Memebers directory: /home/lee/.config/cqrlog/members/
ZIP code directory: /usr/share/cqrlog/zipcodes/
Binary dir: /usr/bin/
Share dir: /usr/share/cqrlog/
*
56 us states loaded
Grid map created
/usr/bin/mysqld
MySQLProcess.Executable: /usr/sbin/mysqld Parameters: --defaults-file=/home/lee/.config/cqrlog/database/mysql.cnf
--datadir=/home/lee/.config/cqrlog/database/
--socket=/home/lee/.config/cqrlog/database/sock
--port=64000

Trying to connect to database
mysqld: Error on realpath() on '/var/lib/mysql-files' (Error 2 - No such file or directory)
2020-01-22T23:31:06.191920Z 0 [ERROR] [MY-010095] [Server] Failed to access directory for --secure-file-priv. Please make sure that directory exists and is accessible by MySQL Server. Supplied value : /var/lib/mysql-files
2020-01-22T23:31:06.191939Z 0 [ERROR] [MY-010187] [Server] Could not open file './mysql.err' for error logging: Permission denied
2020-01-22T23:31:06.191958Z 0 [ERROR] [MY-010119] [Server] Aborting
TMySQL57Connection : Server connect failed.
Trying:1
Trying to connect to database
TMySQL57Connection : Server connect failed.
Trying:2
Trying to connect to database
TMySQL57Connection : Server connect failed.
Trying:3
Trying to connect to database
TMySQL57Connection : Server connect failed.
Trying:4
Trying to connect to database
TMySQL57Connection : Server connect failed.
Trying:5
Trying to connect to database
TMySQL57Connection : Server connect failed.
Trying:6
Trying to connect to database
TMySQL57Connection : Server connect failed.
Trying:7
Trying to connect to database
TMySQL57Connection : Server connect failed.
Trying:8
Closing DXCluster window
Closing TRXControl window
Closing GrayLine window
Closing dDXCC
Closing dData
Closing ini file ...
lee@lee-desktop:~$

Any suggestions please.

K5LY
New Hope, TX
CW Forever

lx2gt
CQRLOG Ubuntu 20.04

CQRLOG actually does run on the mysql server on Focal, with the package provided by the Distribution, however only if you connect to an running one with the system Data directory. Mysql is preferred over mariadb in Ubuntu, because Mysql is in the main repo (supported by Canonical) and mariadb is only supported by the community, and not really updated in my experience. This is what I would always recommend, because of the database upgrades from version to version in the case of distribution upgrades which CQRLOG does not seem to handle on its own, but will be done automatically in the case of upgrades through the repository in the distribution.

You cannot even initialize the Datadir if it does contain files. Yet mysql.cnf is put in ~/.config/cqrlog/database

Aditionally, putting everything in ~/.config/cqrlog/database is a very very bad practice, and might actually be part of the issue. That should be changed one day. I would suggest mysql.cnf to stay in ~/.config/cqrlog/database and the logs itself to be moved to ~/.local/share/cqrlog/database (basedir in mysql terms) and the Databases themselves to ~/.local/share/cqrlog/database/data

This would need code changes, in CQRLOG of course, and would still not solve the potential issue of Database upgrades.

oh1kh
CQRLOG Ubuntu 20.04

"Aditionally, putting everything in ~/.config/cqrlog/database is a very very bad practice, and might actually be part of the issue."

It has it's sides. The most important feature is that you can do absolute full backup of everything just by copying ~/.config/cqrlog with all files and subfolders.
This makes also fast moving to another computer possible by just moving the folder.

I myself have been using external database since beginning of cqrlog use.
When you have to install MySQL/MariaDB server anyway you have already running database in your computer. It runs there and starting cqrlog as "save log to local machine" just starts another SQL server to same computer.

I quote my old message:

---------------------------------------------------------------------------
Instead open console and give:
sudo mysql

If your mysql-server is properly installed and running you should get prompt:

saku@NanoPi-Neo:~$ sudo mysql
Welcome to the MariaDB monitor. Commands end with ; or \g.
Your MariaDB connection id is 38
Server version: 10.0.36-MariaDB-0ubuntu0.16.04.1 Ubuntu 16.04

Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.

Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.

MariaDB [(none)]

Then write line:
GRANT ALL PRIVILEGES ON *.* TO 'cqrlog'@'%' IDENTIFIED BY 'cqrlog';

You will get response like:
Query OK, 0 rows affected (0.04 sec)

Then type:
quit

Go back to cqrlog "Database connection" window.
Uncheck "Save log data to local machine"
Keep address 127.0.0.1 but change port from 64000 to 3306.
username is cqrlog and password is cqrlog.

---------------------------------------------------------------------------

Using installed SQL server at localhost:3306 does not cause any security issues that are preventing second MySQL thread to run at ~/.config/cqrlog/database like in some Linux distributions now happens.

It also allow several computers to use same log (at same time!) and automatic replication to other SQLdatabase servers.

Also worth of mention is DL8BH's CQRWEBLOG ( https://www.dl8bh.de/cqrweblog/ ) that can be run if server has also Apache webserver.
Then additional logging is possible with any web browser device (Tablet, smartphone, PC) and if server has internet connection with public address log can be used from anywhere,

Yes! Hire a web hotel with SQL and use it as your log SQL server and add also cqrweblog there.
You can still use your Hamshack pc as before, log data just lives in web hotel.

Then comes the bad side:

You can not backup everything as easy. You have to make folder copy of ~/.cqnfig/cqrlog and after that mysqldump of logs from your SQL server.

But it is just more work...

--
Saku
OH1KH

lx2gt
Yes, I do that too, having

Yes, I do that too, having the Database on the anyway running SQL Server. Also eases the SQL Server Upgrades. Everything in ~/.local/share/cqrlog would then be more correct, as cqrlog doesn't really have much in configuration files.

Still, the Databases themselves should be in their own directory, as you cannot do an mysqld --initialize on an non-empty directory nowadays...

Luc

DL2KI
Hi,

Hi,

you can check with "dpkg -L cqrlog" if all files have been removed from the package database.

When switching from Ubuntu 19.04 to 19.10 I had considerable problems with the installation of CQRLOG.

After many many tries I could find out that this is related to MySQL. So I replaced MySQL with MariaDB. After that the installation worked.

Before ALL attempts I make a hard disk image with "fsarchiver" on an external USB hard disk to be able to restore the original installation if necessary. It makes sense to invest the time for this.

Unfortunately, information about this procedure can only be found scattered in the forum. I don't know a summarizing description of the problem and the procedure on the part of the developers.

I would therefore recommend to uninstall CQRLOG completely, then replace MySQL with MariaDB and then reinstall CQRLOG again.

Disk images before major changes to the system are generally recommended. Especially if you don't understand the internals as a pure user.

"fsarchiver" has worked here for years without problems. When using it, I boot my system from a USB stick and save the partition with a small script. Copying back a backup works the same way.

I hope that you can help yourself here. Unfortunately I cannot reproduce the problem here.

73, Wolfgang

K5LY
K5LY's picture
Hello Wolfgang,

Hello Wolfgang,

Thanks for your comments. I have uninstalled cqrlog 2.4.0-3
There was a problem uninstalling mysql - keep getting an error, and the uninstall does not complete.
Appears mysql ver 8.0 refuses to leave. Maybe be something pertaining to Ubuntu 20.04 (development branch) It receives daily updates,
If problem is the OS, it may soon be resolved.

Until I am certain mysql is uninstalled I will delay any attempts at installing mariaDB.

I have resorted to using my backup pc with Ubuntu 18.04.3 LTS. It has a perfectly operating copy of cqrlog.
I transfered the database to the backup cqrlog.

Thanks,

73, Lee K5LY

K5LY
New Hope, TX
CW Forever