Setting up Debian testing with Debian Live (cinnamon)

Thomas Papp
6 min readMay 22, 2017

--

Debian testing with cinnamon and Windows 10 Light Theme

1. Create a new or empty text document on the computer you wish to install Debian onto, with the title and extension: 64or32.cmd

2. Edit the file, with a text editor, and add the following:

echo Starting #%0 & @ECHO OFF & GOTO :windows

#### BASH SCRIPT STARTS HERE ####

# Check for OS name, but can't trust uname -a for arch
OS=`uname`

# Detect architecture by abusing an integer overflow
if ((1<<32)); then
ARCH=64 # 64-bit architecture
else
ARCH=32 # 32-bit architecture
fi

# $OS contains OS name, and $ARCH contains the architecture
clear
echo "Hello $OS $ARCH-bit user!"

# Exit before we run into the Windows code
read -n1 -r -p "Press any key to continue..." key
exit

:windows
::#### WINDOWS SCRIPT STARTS HERE ####

:: Determine the architecture by checking Windows' env vars.
IF %PROCESSOR_ARCHITECTURE% == x86 (
SET ARCH=32
) ELSE (
SET ARCH=64
)

:: %ARCH% contains the architecture of the OS
CLS
ECHO Hello Windows %ARCH%-bit user!

:: Exit so the script will not continue into the Linux code
PAUSE
EXIT

3. Save the file, close the text editor, and either double click the file if you’re on Windows, or (if you’re not on Windows) use a terminal and ‘chmod 777 /path/to/64or32.cmd’ <ENTER> then ‘./path/to/64or32.cmd’ <ENTER>

4. Use that architecture number to download the latest version of Debian Live 64-bit or Debian Live 32-bit with the cinnamon desktop environment labeled: debian-live-<version>-<amd64(64-bit)/i386(32-bit)>-cinnamon-desktop.iso

5. Create a bootable CD, DVD or USB of the ISO file you downloaded in order to install the operating system onto your computer.
* Please consult the many tutorials on the web for creating the media you choose.

6. Insert the created CD, DVD or USB into your computer, turn off the computer, turn the computer back on and access the boot menu.
* You may need to search how your particular computer accesses the boot menu.

7. Select the CD, DVD or USB, from the options, to boot into the media.

8. Select the Live option and wait for the system to load.

9. Once the system has loaded, insert an Ethernet cable from your online router to your computer and check the taskbar network icon to assure you have internet access.

10. On the desktop, click the Install Debian icon to begin the installation process.

11. Follow these steps to get through the installation:

  • Choose your location.
  • Enter a desired host name.
  • Enter a desired domain name or leave this blank.
  • Enter a root password.
  • Enter your full name.
  • Enter a short-hand user name.
  • Enter a password for the created user.
  • Choose a time zone.
  • Choose a partitioning scheme and finish the next few steps to your liking until you get to:
  • Choose the mirror based on your location.
  • Choose a mirror host.
  • Add a proxy or leave this blank.
  • Install GRUB and find the disk you partitioned previously until you get to:
  • Finish the installation by shutting down after all is done and removing the media you used to boot into the Live environment.

12. Power on and log into your new system.

13. Open a terminal and type ‘su -’ <ENTER>. Enter the root password.

14. Type ‘visudo’ <ENTER>. Press the down arrow key until you get to the line of code that reads ‘%sudo ALL=(ALL:ALL) ALL’. Add the following under that line: ‘<usrname> ALL=(ALL:ALL) ALL’. Example: ‘trpapp ALL=(ALL:ALL) ALL’

15. Press left CTRL + X, press Y, <ENTER>

16. Type ‘exit’ <ENTER>

17. Type ‘sudo apt-get update’ <ENTER>and enter your users password, wait for the updates.

18. Type ‘sudo apt-get upgrade’ <ENTER>, press Y <ENTER> and wait for it to finish.

19. Type ‘sudo gedit /etc/apt/sources.list’ <ENTER>

20. Change all lines that have HTTP links such that the words following the link is changed to ‘testing’ and ‘main’ is changed to ‘main non-free contrib’. Example(s)= ‘deb http://some.mirror.com/debian jessie/updates main’ to ‘deb http://some.mirror.com/debian testing/updates main non-free contrib’

deb http://mirrors.kernel.org/debian/ testing main non-free contrib
deb-src http://mirrors.kernel.org/debian/ testing main non-free contrib
deb http://security.debian.org/ testing/updates main non-free contrib
deb-src http://security.debian.org/ testing/updates main non-free contrib
deb http://mirrors.kernel.org/debian/ testing-updates main non-free contrib
deb-src http://mirrors.kernel.org/debian/ testing-updates main non-free contrib

21. Save the file and close the editor.

22. Type ‘sudo apt-get update’ <ENTER>, after it’s finished, then type ‘sudo apt-get dist-upgrade’, press Y <ENTER>, wait for the software to install and restart your machine when it finishes (by typing ‘sudo reboot’ into the terminal and entering the users password).
* If popups appear in your terminal, just press Q and if you get asked to restart services, press the arrow key to highlight ‘YES’ and press enter.

You now have Debian testing with cinnamon, upgraded and ready for use! The rest of this article will cover customization and other nuances.

CLEAN-UP: Open a terminal and type ‘sudo apt autoremove’ (enter the users password if prompted).

ANNOYING BEEP: If you hear your computer making annoying beeping sounds, it’s probably the fault of the internal PC speaker (is not the same as the speaker where music can play from). Open a terminal, type ‘su -’ <ENTER>(input the root password) and then enter the following:

modprobe -r pcspkr
echo blacklist pcspkr >> /etc/modprobe.d/blacklist.conf
modprobe -r snd_pcsp
echo blacklist snd_pcsp >> /etc/modprobe.d/blacklist.conf

THEMES: Click the menu and type ‘themes’. Select the themes icon. Here you can change the theme of cinnamon. I’ve opted to add a new desktop theme called ‘Windows 10 Lite Theme’ to mimic the Windows environment.

The controls and window borders section of the theme settings can also be changed to Windows 10. I’ve also selected mate icons and kept the mouse pointer the same.

Remove the menu text by right clicking the menu icon, clicking configure, and remove the Text sections text.

Reboot the system when you are finished themeing.

LOGIN GREETER: The greeter that comes packaged with cinnamon is called LightDM. To customize the greeter, open a terminal and type ‘sudo apt-get install lightdm-gtk-greeter-settings’ <ENTER> (enter the users password if requested). Once it is finished installing, type ‘sudo lightdm-gtk-greeter-settings’ <ENTER> and edit the greeter to your liking. I’ve changed the theme to Adwaita-dark, removed the user image and added a custom background.

--

--

Thomas Papp

Engineer, conservatarian, technologist, truth seeker, gamer & open-source advocate (trpapp.gitlab.io)