-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathLinuxSetupCommands
More file actions
58 lines (45 loc) · 1023 Bytes
/
LinuxSetupCommands
File metadata and controls
58 lines (45 loc) · 1023 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
// Update the repositories
$ sudo su
# apt-get update
// Turn off Swap Space
# swapoff -a
// Comment out the swap.img file
# nano /etc/fstab
//Update the Hostname
# nano /etc/hostname
//Update the host file
# nano /etc/hosts
//Install nettools
apt install net-tools
//IP address
# ifconfig
//Set a static IP address
# nano etc/network/interfaces
//add to above file
# auto enp0s8
# iface enp0s8 inet static
# address <IP ADRESS>
//Edit Yaml file at /etc/netplan/01-netcfg.yaml
network:
version: 2
renderer: networkd
ethernets:
ens18:
dhcp4: no
addresses:
- <Enter Ip address>/24
gateway4: 192.168.2.1
nameservers:
search: [rodriquez.local]
addresses: [192.168.2.19]
//Apply netplan command
sudo netplan apply
//Restart the network service
systemctl restart systemd-networkd
//Install SSH Server
# sudo apt-get install openssh-server
//Generate RSA Key
ssh-keygen -t rsa
//Copy SSH Key out to server
// notnick@192.168.2.20
ssh-copy-id username@x.x.x.x