Sunday, September 1, 2019

Setup ssh on raspberry pi


1. Download image from URL: https://downloads.raspberrypi.org/raspbian_lite_latest

2. Using win32 Disk Image program, write the 2019-06-20-raspbian-buster-full.img to the mini-sd card.

3. Raspbian stretch Lite default login Linux users. User management in Raspbian is done on the command line.

The default
user is pi , and the
password is raspberry .

You can add users and change each user's password.

4. install ssh
 $ sudo apt-get install openssh-server openssh-client

5. Alternatively, use systemctl to start the service
 $ sudo systemctl enable ssh
 $ sudo systemctl start ssh

6. Add user malex
 $ sudo adduser malex

7. Add malex as sudoers
 $ sudo vi /etc/sudoers

 add:
 malex   ALL=(ALL:ALL) ALL

8. passwordless ssh
 $ sudo ls -al ~/.ssh/id_*.pub
 $ sudo ssh-keygen -t rsa -b 4096 -C "azmadriaga@gmail.com"
 $ sudo ssh-copy-id malex@192.168.1.100

9. apt-get install nmap

10. apt-get install xrdp

malex@raspberrypi3:~$ sudo apt-get install xrdp

[sudo] password for malex:
Reading package lists... Done
Building dependency tree
Reading state information... Done
The following additional packages will be installed:
  vnc4server xbase-clients
Suggested packages:
  vnc-java x11-xfs-utils
The following NEW packages will be installed:
  vnc4server xbase-clients xrdp
0 upgraded, 3 newly installed, 0 to remove and 11 not upgraded.
Need to get 1,742 kB of archives.
After this operation, 5,519 kB of additional disk space will be used.
Do you want to continue? [Y/n] y
Get:1 http://ports.ubuntu.com xenial/universe armhf xbase-clients all 1:7.7+13ubuntu3 [4,570 B]
Get:2 http://ports.ubuntu.com xenial/universe armhf vnc4server armhf 4.1.1+xorg4.3.0-37.3ubuntu2 [1,539 kB]
Get:3 http://ports.ubuntu.com xenial/universe armhf xrdp armhf 0.6.1-2 [198 kB]
Fetched 1,742 kB in 4s (370 kB/s)
Selecting previously unselected package xbase-clients.
(Reading database ... 171794 files and directories currently installed.)
Preparing to unpack .../xbase-clients_1%3a7.7+13ubuntu3_all.deb ...
Unpacking xbase-clients (1:7.7+13ubuntu3) ...
Selecting previously unselected package vnc4server.
Preparing to unpack .../vnc4server_4.1.1+xorg4.3.0-37.3ubuntu2_armhf.deb ...
Unpacking vnc4server (4.1.1+xorg4.3.0-37.3ubuntu2) ...
Selecting previously unselected package xrdp.
Preparing to unpack .../xrdp_0.6.1-2_armhf.deb ...
Unpacking xrdp (0.6.1-2) ...
Processing triggers for man-db (2.7.5-1) ...
Processing triggers for systemd (229-4ubuntu21.4) ...
Processing triggers for ureadahead (0.100.0-19) ...
Setting up xbase-clients (1:7.7+13ubuntu3) ...
Setting up vnc4server (4.1.1+xorg4.3.0-37.3ubuntu2) ...
update-alternatives: using /usr/bin/vnc4server to provide /usr/bin/vncserver (vncserver) in auto mode
update-alternatives: using /usr/bin/Xvnc4 to provide /usr/bin/Xvnc (Xvnc) in auto mode
update-alternatives: using /usr/bin/x0vnc4server to provide /usr/bin/x0vncserver (x0vncserver) in auto mode
update-alternatives: using /usr/bin/vnc4passwd to provide /usr/bin/vncpasswd (vncpasswd) in auto mode
update-alternatives: using /usr/bin/vnc4config to provide /usr/bin/vncconfig (vncconfig) in auto mode
Setting up xrdp (0.6.1-2) ...
Processing triggers for systemd (229-4ubuntu21.4) ...
Processing triggers for ureadahead (0.100.0-19) ...

malex@raspberrypi3:~$ sudo service xrdp restart

malex@raspberrypi3:~$ sudo apt-get update

Hit:1 http://ports.ubuntu.com xenial InRelease
Hit:2 http://ppa.launchpad.net/flexiondotorg/minecraft/ubuntu xenial InRelease
Get:3 http://ports.ubuntu.com xenial-updates InRelease [109 kB]
Hit:4 http://ppa.launchpad.net/ubuntu-mate-dev/welcome/ubuntu xenial InRelease
Hit:5 http://ppa.launchpad.net/ubuntu-pi-flavour-makers/ppa/ubuntu xenial InRelease
Get:6 http://ports.ubuntu.com xenial-security InRelease [107 kB]
Get:7 http://ports.ubuntu.com xenial-backports InRelease [107 kB]
Get:8 http://ports.ubuntu.com xenial-updates/main Sources [317 kB]
Get:9 http://ports.ubuntu.com xenial-updates/main armhf Packages [681 kB]
Get:10 http://ports.ubuntu.com xenial-updates/main Translation-en [337 kB]
Get:11 http://ports.ubuntu.com xenial-security/main Sources [130 kB]
Get:12 http://ports.ubuntu.com xenial-security/main armhf Packages [410 kB]
Get:13 http://ports.ubuntu.com xenial-security/main Translation-en [227 kB]
Fetched 2,425 kB in 6s (386 kB/s)
Reading package lists... Done

malex@raspberrypi3:~$ sudo apt-get upgrade

Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages have been kept back:
  libdrm-amdgpu1 libdrm2 libegl1-mesa libgbm1 libgl1-mesa-dri libinput10
  libmm-glib0 libqmi-proxy libwayland-egl1-mesa modemmanager
The following packages will be upgraded:
  libcapnp-0.5.3
1 upgraded, 0 newly installed, 0 to remove and 10 not upgraded.
Need to get 0 B/526 kB of archives.
After this operation, 4,096 B disk space will be freed.
Do you want to continue? [Y/n] y
(Reading database ... 171877 files and directories currently installed.)
Preparing to unpack .../libcapnp-0.5.3_0.5.3-2ubuntu1.1_armhf.deb ...
Unpacking libcapnp-0.5.3:armhf (0.5.3-2ubuntu1.1) over (0.5.3-2ubuntu1) ...
Processing triggers for libc-bin (2.23-0ubuntu10) ...
Setting up libcapnp-0.5.3:armhf (0.5.3-2ubuntu1.1) ...
Processing triggers for libc-bin (2.23-0ubuntu10) ...

malex@raspberrypi3:~$



https://www.fepshop.com/shop/parts/rpi/raspberry-pi-3b-2/

Raspberry Pi 3B+

How to Resize the / using LVM

How to Resize the / using LVM
==============================

Error Summary
-------------
Disk Requirements:
   At least 923MB more space needed on the / filesystem.

[root@thermalite ~]# df -Th
Filesystem              Type      Size  Used Avail Use% Mounted on
devtmpfs                devtmpfs  3.9G     0  3.9G   0% /dev
tmpfs                   tmpfs     3.9G  8.0K  3.9G   1% /dev/shm
tmpfs                   tmpfs     3.9G  1.2M  3.9G   1% /run
tmpfs                   tmpfs     3.9G     0  3.9G   0% /sys/fs/cgroup
/dev/mapper/fedora-root xfs        15G   15G  970M  94% /
tmpfs                   tmpfs     3.9G  4.5M  3.9G   1% /tmp
/dev/sda2               ext4      976M  197M  713M  22% /boot
/dev/sda1               vfat      200M  8.7M  192M   5% /boot/efi
tmpfs                   tmpfs     787M  4.0K  787M   1% /run/user/1000

[root@thermalite ~]# fdisk -l
Disk /dev/sda: 931.5 GiB, 1000204886016 bytes, 1953525168 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes
Disklabel type: gpt
Disk identifier: E39A4721-3CD4-4444-9A32-0F3EE22331B5

Device       Start        End    Sectors   Size Type
/dev/sda1     2048     411647     409600   200M EFI System
/dev/sda2   411648    2508799    2097152     1G Linux filesystem
/dev/sda3  2508800 1953523711 1951014912 930.3G Linux LVM


Disk /dev/mapper/fedora-root: 15 GiB, 16106127360 bytes, 31457280 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes


Disk /dev/mapper/fedora-swap: 7.8 GiB, 8388608000 bytes, 16384000 sectors
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 4096 bytes
I/O size (minimum/optimal): 4096 bytes / 4096 bytes

[root@thermalite ~]# df -Th
Filesystem              Type      Size  Used Avail Use% Mounted on
devtmpfs                devtmpfs  3.9G     0  3.9G   0% /dev
tmpfs                   tmpfs     3.9G  8.0K  3.9G   1% /dev/shm
tmpfs                   tmpfs     3.9G  1.2M  3.9G   1% /run
tmpfs                   tmpfs     3.9G     0  3.9G   0% /sys/fs/cgroup
/dev/mapper/fedora-root xfs        15G   15G  971M  94% /
tmpfs                   tmpfs     3.9G  4.5M  3.9G   1% /tmp
/dev/sda2               ext4      976M  197M  713M  22% /boot
/dev/sda1               vfat      200M  8.7M  192M   5% /boot/efi
tmpfs                   tmpfs     787M  4.0K  787M   1% /run/user/1000

[root@thermalite ~]# lsblk
NAME            MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda               8:0    0 931.5G  0 disk
├─sda1            8:1    0   200M  0 part /boot/efi
├─sda2            8:2    0     1G  0 part /boot
└─sda3            8:3    0 930.3G  0 part
  ├─fedora-root 253:0    0    15G  0 lvm  /
  └─fedora-swap 253:1    0   7.8G  0 lvm  [SWAP]

[root@thermalite ~]# sudo parted /dev/sda
GNU Parted 3.2
Using /dev/sda
Welcome to GNU Parted! Type 'help' to view a list of commands.
(parted) unit GB
(parted) print
Model: ATA WDC WD10EZEX-00B (scsi)
Disk /dev/sda: 1000GB
Sector size (logical/physical): 512B/4096B
Partition Table: gpt
Disk Flags:

Number  Start   End     Size    File system  Name                  Flags
 1      0.00GB  0.21GB  0.21GB  fat16        EFI System Partition  boot, esp
 2      0.21GB  1.28GB  1.07GB  ext4
 3      1.28GB  1000GB  999GB                                      lvm

(parted) q

[root@thermalite ~]# pvdisplay
  --- Physical volume ---
  PV Name               /dev/sda3
  VG Name               fedora
  PV Size                 Allocatable           yes
  PE Size               4.00 MiB
  Total PE              238160
  Free PE               232320
  Allocated PE          5840
  PV UUID               etHzhN-vONC-31VY-qdA5-zcWx-Drsq-52CcO6

[root@thermalite ~]# pvs
  PV         VG     Fmt  Attr PSize   PFree
  /dev/sda3  fedora lvm2 a--  930.31g 907.50g

[root@thermalite ~]# vgdisplay
  --- Volume group ---
  VG Name               fedora
  System ID
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  3
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                2
  Open LV               2
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               930.31 GiB
  PE Size               4.00 MiB
  Total PE              238160
  Alloc PE / Size       5840 / 22.81 GiB
  Free  PE / Size       232320 / 907.50 GiB
  VG UUID               l3ifpd-93Wv-Y8Wl-4I31-CBnH-gxt5-2BYg7v

[root@thermalite ~]# vgdisplay -v
  --- Volume group ---
  VG Name               fedora
  System ID
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  3
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                2
  Open LV               2
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               930.31 GiB
  PE Size               4.00 MiB
  Total PE              238160
  Alloc PE / Size       5840 / 22.81 GiB
  Free  PE / Size       232320 / 907.50 GiB
  VG UUID               l3ifpd-93Wv-Y8Wl-4I31-CBnH-gxt5-2BYg7v

  --- Logical volume ---
  LV Path                /dev/fedora/swap
  LV Name                swap
  VG Name                fedora
  LV UUID                sW7ldx-Jqwk-2Bxu-ptej-ekok-sKRg-Rd3H2a
  LV Write Access        read/write
  LV Creation host, time localhost, 2018-08-04 16:53:32 -0400
  LV Status              available
  # open                 2
  LV Size                7.81 GiB
  Current LE             2000
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:1

  --- Logical volume ---
  LV Path                /dev/fedora/root
  LV Name                root
  VG Name                fedora
  LV UUID                SRHprS-qKyi-tNfo-f71c-UOEE-fBQL-y7rBYe
  LV Write Access        read/write
  LV Creation host, time localhost, 2018-08-04 16:53:32 -0400
  LV Status              available
  # open                 1
  LV Size                15.00 GiB
  Current LE             3840
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:0

  --- Physical volumes ---
  PV Name               /dev/sda3
  PV UUID               etHzhN-vONC-31VY-qdA5-zcWx-Drsq-52CcO6
  PV Status             allocatable
  Total PE / Free PE    238160 / 232320

[root@thermalite ~]# lvextend -L+100G /dev/fedora/root
  Size of logical volume fedora/root changed from 15.00 GiB (3840 extents) to 115.00 GiB (29440 extents).
  Logical volume fedora/root successfully resized.


[root@thermalite ~]# vgdisplay -v
  --- Volume group ---
  VG Name               fedora
  System ID
  Format                lvm2
  Metadata Areas        1
  Metadata Sequence No  4
  VG Access             read/write
  VG Status             resizable
  MAX LV                0
  Cur LV                2
  Open LV               2
  Max PV                0
  Cur PV                1
  Act PV                1
  VG Size               930.31 GiB
  PE Size               4.00 MiB
  Total PE              238160
  Alloc PE / Size       31440 / 122.81 GiB
  Free  PE / Size       206720 / 807.50 GiB
  VG UUID               l3ifpd-93Wv-Y8Wl-4I31-CBnH-gxt5-2BYg7v

  --- Logical volume ---
  LV Path                /dev/fedora/swap
  LV Name                swap
  VG Name                fedora
  LV UUID                sW7ldx-Jqwk-2Bxu-ptej-ekok-sKRg-Rd3H2a
  LV Write Access        read/write
  LV Creation host, time localhost, 2018-08-04 16:53:32 -0400
  LV Status              available
  # open                 2
  LV Size                7.81 GiB
  Current LE             2000
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:1

  --- Logical volume ---
  LV Path                /dev/fedora/root
  LV Name                root
  VG Name                fedora
  LV UUID                SRHprS-qKyi-tNfo-f71c-UOEE-fBQL-y7rBYe
  LV Write Access        read/write
  LV Creation host, time localhost, 2018-08-04 16:53:32 -0400
  LV Status              available
  # open                 1
  LV Size                115.00 GiB
  Current LE             29440
  Segments               1
  Allocation             inherit
  Read ahead sectors     auto
  - currently set to     256
  Block device           253:0

  --- Physical volumes ---
  PV Name               /dev/sda3
  PV UUID               etHzhN-vONC-31VY-qdA5-zcWx-Drsq-52CcO6
  PV Status             allocatable
  Total PE / Free PE    238160 / 206720

[root@thermalite ~]# df -Th
Filesystem              Type      Size  Used Avail Use% Mounted on
devtmpfs                devtmpfs  3.9G     0  3.9G   0% /dev
tmpfs                   tmpfs     3.9G  8.0K  3.9G   1% /dev/shm
tmpfs                   tmpfs     3.9G  1.2M  3.9G   1% /run
tmpfs                   tmpfs     3.9G     0  3.9G   0% /sys/fs/cgroup
/dev/mapper/fedora-root xfs        15G   15G  971M  94% /
tmpfs                   tmpfs     3.9G  4.5M  3.9G   1% /tmp
/dev/sda2               ext4      976M  197M  713M  22% /boot
/dev/sda1               vfat      200M  8.7M  192M   5% /boot/efi
tmpfs                   tmpfs     787M  4.0K  787M   1% /run/user/1000

[root@thermalite ~]# lsblk
NAME            MAJ:MIN RM   SIZE RO TYPE MOUNTPOINT
sda               8:0    0 931.5G  0 disk
├─sda1            8:1    0   200M  0 part /boot/efi
├─sda2            8:2    0     1G  0 part /boot
└─sda3            8:3    0 930.3G  0 part
  ├─fedora-root 253:0    0   115G  0 lvm  /
  └─fedora-swap 253:1    0   7.8G  0 lvm  [SWAP]

[root@thermalite ~]# pvresize /dev/sda3
  Physical volume "/dev/sda3" changed
  1 physical volume(s) resized / 0 physical volume(s) not resized

[root@thermalite ~]# pvs
  PV         VG     Fmt  Attr PSize   PFree
  /dev/sda3  fedora lvm2 a--  930.31g 807.50g

[root@thermalite ~]# vgs
  VG     #PV #LV #SN Attr   VSize   VFree
  fedora   1   2   0 wz--n- 930.31g 807.50g

[root@thermalite ~]# lvextend -l +100%FREE /dev/mapper/fedora-root
  Size of logical volume fedora/root changed from 115.00 GiB (29440 extents) to 922.50 GiB (236160 extents).
  Logical volume fedora/root successfully resized.

[root@thermalite ~]# df -Th
Filesystem              Type      Size  Used Avail Use% Mounted on
devtmpfs                devtmpfs  3.9G     0  3.9G   0% /dev
tmpfs                   tmpfs     3.9G  8.0K  3.9G   1% /dev/shm
tmpfs                   tmpfs     3.9G  1.2M  3.9G   1% /run
tmpfs                   tmpfs     3.9G     0  3.9G   0% /sys/fs/cgroup
/dev/mapper/fedora-root xfs        15G   15G  970M  94% /
tmpfs                   tmpfs     3.9G  4.5M  3.9G   1% /tmp
/dev/sda2               ext4      976M  197M  713M  22% /boot
/dev/sda1               vfat      200M  8.7M  192M   5% /boot/efi
tmpfs                   tmpfs     787M  4.0K  787M   1% /run/user/1000

[root@thermalite ~]# pvs
  PV         VG     Fmt  Attr PSize   PFree
  /dev/sda3  fedora lvm2 a--  930.31g    0

[root@thermalite ~]# df -hT | grep mapper
/dev/mapper/fedora-root xfs        15G   15G  970M  94% /

[root@thermalite ~]# sudo resize2fs /dev/mapper/fedora-root
resize2fs 1.44.2 (14-May-2018)
resize2fs: Bad magic number in super-block while trying to open /dev/mapper/fedora-root
Couldn't find valid filesystem superblock.

[root@thermalite ~]# xfs_growfs /
meta-data=/dev/mapper/fedora-root isize=512    agcount=4, agsize=983040 blks
         =                       sectsz=4096  attr=2, projid32bit=1
         =                       crc=1        finobt=1 spinodes=0 rmapbt=0
         =                       reflink=0
data     =                       bsize=4096   blocks=3932160, imaxpct=25
         =                       sunit=0      swidth=0 blks
naming   =version 2              bsize=4096   ascii-ci=0 ftype=1
log      =internal               bsize=4096   blocks=2560, version=2
         =                       sectsz=4096  sunit=1 blks, lazy-count=1
realtime =none                   extsz=4096   blocks=0, rtextents=0
data blocks changed from 3932160 to 241827840
[root@thermalite ~]# df -hT | grep mapper
/dev/mapper/fedora-root xfs       923G   15G  908G   2% /
[root@thermalite ~]# df -Th
Filesystem              Type      Size  Used Avail Use% Mounted on
devtmpfs                devtmpfs  3.9G     0  3.9G   0% /dev
tmpfs                   tmpfs     3.9G  8.0K  3.9G   1% /dev/shm
tmpfs                   tmpfs     3.9G  1.2M  3.9G   1% /run
tmpfs                   tmpfs     3.9G     0  3.9G   0% /sys/fs/cgroup
/dev/mapper/fedora-root xfs       923G   15G  908G   2% /
tmpfs                   tmpfs     3.9G  4.5M  3.9G   1% /tmp
/dev/sda2               ext4      976M  197M  713M  22% /boot
/dev/sda1               vfat      200M  8.7M  192M   5% /boot/efi
tmpfs                   tmpfs     787M  4.0K  787M   1% /run/user/1000
[root@thermalite ~]# 
https://invalidmagic.wordpress.com/2012/04/28/booting-nixos-from-lvm-on-top-of-mdadm-using-gpt/

booting nixos from lvm on top of mdadm using GPT

PosgresSQL Error: "psql: could not connect to server: Connection refused"

Use nmap to get list of active IP addresses on the network

[malex@thermalite ~]$ nmap -sP 192.168.1.1/24

Starting Nmap 7.60 ( https://nmap.org ) at 2019-08-03 12:03 EDT
Nmap scan report for Fios_Quantum_Gateway.fios-router.home (192.168.1.1)
Host is up (0.00059s latency).
Nmap scan report for 192.168.1.100
Host is up (0.00011s latency).
Nmap scan report for 192.168.1.114
Host is up (0.0011s latency).
Nmap scan report for localhost.fios-router.home (192.168.1.151)
Host is up (0.0010s latency).
Nmap scan report for iPhone7-Cheche.fios-router.home (192.168.1.155)
Host is up (0.012s latency).
Nmap scan report for 192.168.1.157
Host is up (0.023s latency).
Nmap scan report for 192.168.1.223
Host is up (0.0061s latency).
Nmap scan report for raspberrypi312.fios-router.home (192.168.1.229)
Host is up (0.0042s latency).
Nmap scan report for raspberrypi313.fios-router.home (192.168.1.233)
Host is up (0.0054s latency).
Nmap scan report for raspberrypi313.fios-router.home (192.168.1.234)
Host is up (0.0053s latency).
Nmap scan report for raspberrypi1.fios-router.home (192.168.1.235)
Host is up (0.0052s latency).
Nmap scan report for RE6500-391.fios-router.home (192.168.1.248)
Host is up (0.0010s latency).
Nmap scan report for raspberrypi.fios-router.home (192.168.1.249)
Host is up (0.11s latency).
Nmap scan report for raspberrypi1.fios-router.home (192.168.1.250)
Host is up (0.0015s latency).
Nmap scan report for raspberrypi312.fios-router.home (192.168.1.254)
Host is up (0.015s latency).
Nmap done: 256 IP addresses (15 hosts up) scanned in 3.85 seconds
[malex@thermalite ~]$

Installing Jenkins on Fedora 28

1. Remove Java and Jenkins
   [root@thermalite ~]# yum remove jenkins
   [root@thermalite ~]# yum remove java

2. Install Jenkins, Java and Git
   [root@thermalite ~]# wget -O /etc/yum.repos.d/jenkins.repo http://pkg.jenkins-ci.org/redhat/jenkins.repo
   [root@thermalite ~]# rpm --import http://pkg.jenkins-ci.org/redhat/jenkins-ci.org.key
   [root@thermalite ~]# yum install jenkins java git -y

3. Start Jenkins service
   [root@thermalite ~]# systemctl start jenkins.service
   [root@thermalite ~]# systemctl stop jenkins.service
   [root@thermalite ~]# systemctl start jenkins.service
   [root@thermalite ~]# systemctl status jenkins.service

4. Check firewall
[root@thermalite ~]# firewall-cmd --get-active-zones
home
  interfaces: enp2s0

[root@thermalite ~]# firewall-cmd --list-all
home (active)
  target: default
  icmp-block-inversion: no
  interfaces: enp2s0
  sources:
  services: ssh mdns samba-client dhcpv6-client http jenkins
  ports:
  protocols:
  masquerade: no
  forward-ports:
  source-ports:
  icmp-blocks:
  rich rules:

[root@thermalite ~]#

5. Open browser url: http://192.168.1.100:8080

6. Edit /etc/sysconfig/jenkins to change port from 8080 to 9191
     JENKINS_PORT="9191"

7. Restart Jenkins
[root@thermalite ~]# systemctl stop jenkins
[root@thermalite ~]# systemctl start jenkins
[root@thermalite ~]# systemctl status jenkins


sudo usermod -s /bin/bash jenkins
sudo usermod -m /var/lib/jenkins jenkins
sudo su - jenkins
curl -L https://get.rvm.io | bash -s stable --rails --autolibs=enabled

Installing a Raspbian

1. Download image from URL: https://downloads.raspberrypi.org/raspbian_lite_latest

2. Using win32 Disk Image program, write the 2019-06-20-raspbian-buster-full.img to the mini-sd card.

3. Raspbian stretch Lite default login Linux users. User management in Raspbian is done on the command line.

The default
user is pi , and the
password is raspberry .

You can add users and change each user's password.

4. install ssh
 $ sudo apt-get install openssh-server openssh-client

5. Alternatively, use systemctl to start the service
 $ sudo systemctl enable ssh
 $ sudo systemctl start sshapt-get

6. Add user malex
 $ sudo adduser malex

7. Add malex as sudoers
 $ sudo vi /etc/sudoers

 add:
 malex   ALL=(ALL:ALL) ALL

8. passwordless ssh
 $ sudo ls -al ~/.ssh/id_*.pub
 $ sudo ssh-keygen -t rsa -b 4096 -C "azmadriaga@gmail.com"
 $ sudo ssh-copy-id malex@192.168.1.100

9. sudo apt-get install nmap

10. sudo apt-get install xrdp

TBD



TBD