Steps for Linux post-installation tasks

From Wiki
Jump to navigation Jump to search

Install Linux

First step is to install Linux. For Hyper-V VMs, 1024 MB of RAM is typically more than enough. Sometimes 512 will be plenty.

Set up the NAS

  1. Install cifs-utils
    1. sudo apt-get update
    2. sudo apt-get install cifs-utils
  2. Make directory /mnt/Storage
    1. sudo mkdir /mnt/Storage
  3. Enter the below into /etc/fstab (sudo nano /etc/fstab)
    1. //10.10.10.20/Storage /mnt/Storage cifs guest,uid=1000,iocharset=utf8 0 0
  4. Run sudo mount-a

Set up SSH access

  1. On cougar, run ssh-copy-id <ip address> and answer prompts.
  2. SSH into the machine to make sure it works.
  3. Run sudo nano /etc/ssh/sshd_config
    1. Change #PasswordAuthentication yes to PasswordAuthentication no
    2. Reload ssh by running sudo service ssh restart
    3. To test whether everything is working, ssh into another Linux server and test by attempting to ssh into the server you're setting up. It should fail with a Permission denied (pubkey). If not, then recheck changing the SSH config.

Add the DNS record to the DNS server

  1. Remote into Zeus (Or launch the DNS Management Console on cougar as an administrator (lbrandt), then proceed to step 3)
  2. Launch the DNS Management Console
  3. Expand Forward Lookup Zones.
  4. Click on lukebrandt.com
  5. Right-click on lukebrandt.com, then select New Host (A or AAAA)
  6. Enter the computer name, IP Address, and verify that the PTR checkbox is checked.
  7. The DNS record should now be added!

Add the server to guacamole

  1. Navigate to the guacamole web console
  2. Click on guacadmin in the upper right-hand corner, then click on Settings
  3. Click on Connections
  4. Click on any of the existing Linux servers
  5. Scroll down to the bottom and click Clone
  6. Change the Name and the Hostname fields to match the new server.
  7. Click Save.
  8. The new server is now available in guacamole.

Add the server to landscape

  1. SSH into the new server
  2. Run sudo apt update
  3. Run sudo apt install landscape-client
  4. Run sudo landscape-config --computer-title "My Web Server" --account-name standalone --url https://landscape.lukebrandt.com/message-system --ping-url http://landscape.lukebrandt.com/ping, replacing "My Web Server" with the name of the new server.
    1. If you get an error regarding the internet being down, change the landscape.lukebrandt.com part of the URLs to the IP address of the server.
  5. Accept most of the defaults. When prompted for script users, enter luke. Use the server name as the tag and production as the Access Group.
  6. Once you add as a new registration, there will most likely be an error regarding an ssl_public_key
    1. To rectify this, run sudo cp /mnt/Storage/Dropbox/landscape_server_ca.crt /etc/landscape/
    2. Then run sudo nano /etc/landscape/client.conf
    3. Change or add the following line: ssl_public_key = /etc/landscape/landscape_server_ca.crt
    4. Run the registration again, accepting all the defaults. It should now register.
  7. Once the terminal reports that the registration is successful, navigate to the landscape web console Pending Computers page. There should be an alert waiting for a computer to be registered.
  8. Click on the computer waiting registration and Accept it.
  9. The server should now be added to landscape.