Linux Category



Scaleway Centos 7 GPG key yum update problem

No Comments »

Got the following yum update error when launching Scaleway C2 server powered by Centos 7:


warning: /var/cache/yum/armhfp/7/base/packages/firewalld-0.3.9-14.el7.noarch.rpm: Header V3 RSA/SHA256 Signature, key ID f4a80eb5: NOKEY
Retrieving key from file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-AltArch-Arm32


The GPG keys listed for the “CentOS-7 – Base” repository are already installed but they are not correct for this package.
Check that the correct key URLs are configured for this repository.

Failing package is: firewalld-0.3.9-14.el7.noarch
GPG Keys are configured as: file:///etc/pki/rpm-gpg/RPM-GPG-KEY-CentOS-SIG-AltArch-Arm32

Clearly shows GPG key is missing and yum stops there… This is how to fix it in less than 10 seconds:

rpm --import https://www.centos.org/keys/RPM-GPG-KEY-CentOS-7

and try to run yum Read the rest of this entry »


Scaleway cloud server SSH key login problem

No Comments »

I have been playing around with Scaleway bare metal cloud servers and experienced problems with logging into my newly created server. My local PC is Ubuntu 16.04 and I added SSH key to Scaleway, but when connected with the following command

ssh -i my_key.pub root@123.123.123.123

I got the following error:

sign_and_send_pubkey: signing failed: agent refused operation

and couldn’t login. Then, I found out that I have to execute the following command on my local workstation to successfully login into scaleway box:

ssh-add

Please note that if you add your scaleway SSH key in their control panel after you have created … Read the rest of this entry »


NO_PUBKEY A902DDA375E52366

No Comments »

Ubuntu Intel video card repository at 01.org requires a custom public key imported before you can proceed. The usual error method you will be getting is like this:

W: GPG error: https://download.01.org trusty InRelease: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY A902DDA375E52366

To fix this issue do the following:

sudo apt-key adv ––keyserver keyserver.ubuntu.com ––recv-keys A902DDA375E52366

 

Rember it’s dash-dash (––) in command line.

It should be fixed. For reference, I am including full log:

Executing: gpg –ignore-time-conflict –no-options –no-default-keyring –homedir /tmp/tmp.35JCw7DjiB –no-auto-check-trustdb –trust-model always –keyring /etc/apt/trusted.gpg –primary-keyring /etc/apt/trusted.gpg –keyserver keyserver.ubuntu.com –recv-keys A902DDA375E52366… Read the rest of this entry »


Playing DVD movies on Ubuntu 14.04

No Comments »

I installed ASUS DVD drive and had to figure out how to play encrypted DVDs that were scrambled with Content Scramble System (CSS).

First, I installed VLC player and tried to play video file(s) without success. The following error message was displayed:

libdvdnav: Using dvdnav version 4.2.1
libdvdread: Attempting to use device /dev/sr0 mounted on /media/XX/CATLOW for CSS authentication
libdvdnav: Can't read name block. Probably not a DVD-ROM device.
libdvdnav: Unable to find map file '/home/XX/.dvdnav/.map'
libdvdnav: DVD disk reports itself with Region mask 0x00f00000. Regions: 1 2 3 4
libdvdnav: Suspected RCE Region Protection!!!

Did some googling around and … Read the rest of this entry »


Display count of all TCP connections on a Linux server or workstation

No Comments »

Display all  TCP connections on a Linux based server (execute the command below from ROOT user):

netstat -an|awk ‘/tcp/ {print $6}’|sort|uniq -c

Should output something like:

     45 ESTABLISHED
      7 LISTEN
      2 TIME_WAIT

Read the rest of this entry »

Percona 1C4CBDCDCD2EFD2A key importing

No Comments »

Getting error with downloading and installing Percona Public GPG key on Debian or Ubuntu?

W: GPG error: http://repo.percona.com squeeze Release: The following signatures couldn’t be verified because the public key is not available: NO_PUBKEY 1C4CBDCDCD2EFD2A
Run the following command:

gpg –keyserver pgp.mit.edu –recv-keys 1C4CBDCDCD2EFD2A

it will output:

gpg: directory `/root/.gnupg’ created
gpg: new configuration file `/root/.gnupg/gpg.conf’ created
gpg: WARNING: options in `/root/.gnupg/gpg.conf’ are not yet active during this run
gpg: keyring `/root/.gnupg/secring.gpg’ created
gpg: keyring `/root/.gnupg/pubring.gpg’ created
gpg: requesting key CD2EFD2A from hkp server pgp.mit.edu
gpg: /root/.gnupg/trustdb.gpg: trustdb created
gpg: key CD2EFD2A: public key “Percona MySQL Development Team <mysql-dev@percona.com>” imported

Read the rest of this entry »

Change the default editor in Debian Linux

No Comments »

You can change default editor in Debian Linux with the following command:

 update-alternatives –config editor

This will bring up the following screen asking you to select the editor (number on the Selection field):

There are 9 choices for the alternative editor (providing /usr/bin/editor).

Selection    Path                Priority   Status
————————————————————
* 0            /usr/bin/joe         70        auto mode
  1            /bin/nano            40        manual mode
  2            /usr/bin/jmacs       50        manual mode
  3            /usr/bin/joe         70        manual mode
  4            /usr/bin/jpico       50        manual mode
  5            /usr/bin/jstar       50        manual mode
  6            /usr/bin/mcedit      25        manual mode
  7            /usr/bin/rjoe        25        manual mode
  8            /usr/bin/vim.basic   30        manual mode
  9            /usr/bin/vim.tiny    10        manual mode

Press

Read the rest of this entry »

Safe and secure Linux disc shredding

No Comments »

Today, when cloud servers are so popular always remember to wipe out your server data when you are deleting your VPS node or returning a dedicated server.

If you are running Debian it’s easy to install a secure-delete utility with the following utilities:

srm – securely delete an existing file
smem – securely delete traces of a file from ram
sfill – wipe all the space marked as empty on your hard drive
sswap – wipe all the data from you swap space.

To install secure-delete tools, run the following command with ROOT privileges:

apt-get install secure-delete

To safely shred … Read the rest of this entry »


Puppet problem. Could not retrieve hostname: getaddrinfo: Name or service not known

No Comments »

Puppet agent error message:

Could not retrieve hostname: getaddrinfo: Name or service not known
Could not retrieve hostname: getaddrinfo: Name or service not known
dnsdomainname: Name or service not known
/usr/lib/ruby/1.8/puppet/defaults.rb:190: undefined method `downcase' for nil:NilClass (NoMethodError)
from /usr/lib/ruby/1.8/puppet.rb:100:in `require'
from /usr/lib/ruby/1.8/puppet.rb:100
from /usr/lib/ruby/1.8/puppet/application.rb:278:in `require'
from /usr/lib/ruby/1.8/puppet/application.rb:278:in `initialize'
from /usr/lib/ruby/1.8/puppet/util/command_line.rb:55:in `new'
from /usr/lib/ruby/1.8/puppet/util/command_line.rb:55:in `execute'
from /usr/bin/puppet:4

You fix the above error message by editing /etc/hosts file and make sure your server domain name resolves to your public interface IP (or 127.0.0.1). Then run once again “puppet agent –test“… Read the rest of this entry »


Puppet agent error: err: Could not retrieve catalog from remote server: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed

1 Comment »

You may be also banging your head against the wall and experiencing the same problem I was experiencing earlier today. I tried updated server configuration via “puppet agent –test” utility and received the following error message:

err: Could not retrieve catalog from remote server: SSL_connect returned=1 errno=0 state=SSLv3 read server certificate B: certificate verify failed
warning: Not using cache on failed catalog
err: Could not retrieve catalog; skipping run

So finally it turned out that NTP was not running on the client server OS and the time was set back in 2010 year! After setting up ntp daemon … Read the rest of this entry »