OnWorks Linux and Windows Online WorkStations

Logo

Free Hosting Online for WorkStations

< Previous | Contents | Next >

6.4.2. Remote Kernel Crash Dumps using the SSH protocol


To enable remote dumps using the SSH protocol, the /etc/default/kdump-tools must be modified in the following manner :


# ---------------------------------------------------------------------------

# Remote dump facilities:

# SSH - username and hostname of the remote server that will receive the dump

# and dmesg files.

# SSH_KEY - Full path of the ssh private key to be used to login to the remote

# server. use kdump-config propagate to send the public key to the

# remote server

# HOSTTAG - Select if hostname of IP address will be used as a prefix to the

# timestamped directory when sending files to the remote server.

# 'ip' is the default.

SSH="ubuntu@kdump-netcrash"


The only mandatory variable to define is SSH. It must contain the username and hostname of the remote server using the format {username}@{remote server}.

SSH_KEY may be used to provide an existing private key to be used. Otherwise, the kdump-config propagate command will create a new keypair. The HOSTTAG variable may be used to use the hostname of the system as a prefix to the remote directory to be created instead of the IP address.

The following example shows how kdump-config propagate is used to create and propagate a new keypair to the remote server :



sudo kdump-config propagate

Need to generate a new ssh key...

The authenticity of host 'kdump-netcrash (192.168.1.74)' can't be established. ECDSA key fingerprint is SHA256:iMp+5Y28qhbd+tevFCWrEXykDd4dI3yN4OVlu3CBBQ4.

Are you sure you want to continue connecting (yes/no)? yes ubuntu@kdump-netcrash's password:

propagated ssh key /root/.ssh/kdump_id_rsa to server ubuntu@kdump-netcrash


The password of the account used on the remote server will be required in order to successfully send the public key to the server


The kdump-config show command can be used to confirm that kdump is correctly configured to use the SSH protocol :


kdump-config show

DUMP_MODE: kdump

USE_KDUMP: 1

KDUMP_SYSCTL: kernel.panic_on_oops=1 KDUMP_COREDIR: /var/crash

crashkernel addr: 0x2c000000

/var/lib/kdump/vmlinuz: symbolic link to /boot/vmlinuz-4.4.0-10-generic kdump initrd:

/var/lib/kdump/initrd.img: symbolic link to /var/lib/kdump/initrd.img-4.4.0-10-generic

SSH: ubuntu@kdump-netcrash

SSH_KEY: /root/.ssh/kdump_id_rsa

HOSTTAG: ip

current state: ready to kdump


Top OS Cloud Computing at OnWorks: