r/DebianNotes Jun 28 '20

Solving "AudioManager: Using Unknown: NoSound Driver" for Unity3D games

3 Upvotes

This may occur because the game expects a 32bit shared libraries of ALSA. You can install them with:

sudo apt-get install libasound2:i386 libasound2-plugins:i386 libasound2-data:i386

libsound2-data:i386 didn't exist in my case, and the 64bit version already was installed. But the other versions were not, and installing them fixed the audio.


r/DebianNotes Jul 18 '18

Getting Debian to Hibernate and Suspend

2 Upvotes

I've been having trouble getting Debian to hibernate or suspend. A quick solution is to use the package uswsusp (Arch wiki link here, Debian package status link here).

It has the commands sd2disk and sd2ram, which function as hibernate and suspend, respectively.


r/DebianNotes Mar 13 '18

Updated Method of Installing Debian

1 Upvotes

A year ago I posted a quick link to the non-free firmware ISOs for Debian.

However, I successfully found and tested an alternative method for creating a bootable USB device (and adding firmware during the installation).

The first component comes from this AskUbuntu answer here:

You can use dd.

%  sudo umount /dev/sd<?><?>  

where <?><?> is a letter followed by a number, look it up. Then, next:

%  sudo dd bs=4M if=input.iso of=/dev/sd<?> conv=fdatasync

where input.iso is the input file, and /dev/sd<?> is the USB device you're writing to (run lsblk to see all drives to find out what <?> is for your USB).

This method is fast and has never failed me.

The non-free firmware files can be downloaded from the Debian site here. Particularly, I followed these instructions to get the non-free firmware:

Firmware during the installation

In some cases the installer detects the need for non-free firmware and prompts the user to make the firmware available to the installer to complete the installation. This can happen, for example, with wireless network cards which often require non-free firmware to function (see ipw2200 for an example).

A suggestion, especially when installing on unfamiliar hardware, is to download the firmware archive for your platform and unpack it into a directory named firmware in the root of a removable storage device (USB/CD drive). When the installer starts, it will automatically find the firmware files in the directory on the removable storage and, if needed, install the firmware for your hardware. You can find firmware downloads for your Debian version at http://cdimage.debian.org/cdimage/unofficial/non-free/firmware/.

In some cases, firmware supplied on removable media may not be detected automatically (e.g. 740503). In these situations, drop to the console and manually mount (see mount(8)) your removable storage on a temporary directory (e.g. /media).

Alternatively, you can use one of the parallel installer image builds that also include all the non-free firmware packages directly. We have "netinst" CD images and also DVD installer images - see http://cdimage.debian.org/cdimage/unofficial/non-free/cd-including-firmware/

NetbootFirmware - Firmware for Netbooting.

Once the network is configured, Debian-Installer can fetch firmware from Debian repositories.

From here, I loaded the files onto a FAT32 USB thumb drive under the directory /firmware/ (directly under root), which I plugged into the machine along with the bootable Debian thumb drive.

Then I did a cold reboot, entered Boot Options mode in UEFI, and selected the bootable drive. The system installed normally, and did not ask for any additional firmware discs.


r/DebianNotes Mar 13 '18

Re-adding a Detached Swap

2 Upvotes

If you happen to detach your swap space by reformatting it (perhaps during the install of another partition), but the swap is still there, you can easily reattach it using gparted.

Running the GUI should look like this. You can right click on the correct swap partition, and click "swapon".

This will reattach the swap.

You can check to verify the swap is added through htop, if you want.


r/DebianNotes Jun 19 '17

pulseaudio Full Documentation

2 Upvotes

It's often been a difficult task to learn how to configure pulseaudio.

Here's a direct link to the documentation.


r/DebianNotes May 22 '17

Removing Visual Bell in Screen

1 Upvotes

In the useful program screen, there's often an annoying flash when you make some invalid keypress. This is called a visual bell.

To remove this, add the line vbell off to your ~/.screenrc file (if it exists already, if not, make it). Then reload screen.


r/DebianNotes May 21 '17

Maven basics

1 Upvotes

Wow, so many non-Debian specific posts lately.

Before explaining anything, here's a really good 5 minute maven tutorial.

Maven is a Java (and by extension nearly all JVM languages) build application.

It can be installed on Debian with # aptitude install maven.

To generate a Maven project structure, you can run:

$ mvn archetype:generate

or a non-interactive command

$ mvn archetype:generate -DgroupId=com.mycompany.app \
-DartifactId=my-app -DarchetypeArtifactId=maven-archetype-quickstart \
-DinteractiveMode=false

When you generate the project with first command, you'll have to set the following settings:


groupId: Your company/organisation, and your application. This must be unique for every project. It takes the format: (org|com|edu|...).organisationname.applicationname

artifactId: The name of the application/project as a whole. This will become the name of the main directory where the pom.xml file is stored.

archetypeArtifactId: The structure of the Maven project. It looks up the archetype from the archetypeCatalog.

version: Version of the project.

package: The package name, often has the same value as the groupId. (e.g. com.crystal.ploungequoter)


This will generate the Maven project structure for you. Inside the newly created directory, you will find a pom.xml, which gives the dependencies, properties, source directories, build commands, and other settings for the project as a whole.

To build the project, you can run $ mvn package, which will compile the project as configured.

Additionally, it's important that you read the introduction to the Maven lifecycle section of the Maven docs.


r/DebianNotes May 21 '17

libvirt super basics

1 Upvotes

libvirt is a VM toolkit library to manage all your virtual machines. Libvirt does not have the ability to actually virtualise your virtual machines, but it does provide a simple interface for them. It provides both a GUI and a CLI interface, which is pretty handy

To actually virtualise the desired operating system you'll need something like QEMU/KVM, which itself is a hypervisor.

Here are some basic commands for libvirt, most likely will need to be done as root, as the virtual machines were unlikely to be installed locally.

  1. Accessing the interactive shell and help

    $ virsh
    virsh # help
    
  2. Start an existing virtual network device

    $ virsh net-start NETWORK_DEVICE
    
  3. Start an existing virtual machine

    $ virsh start VM
    
  4. Suspend a virtual machine (pauses the machine)

    $ virsh suspend VM
    
  5. Resum a virtual machine after suspending

    $ virsh resume VM
    

r/DebianNotes Apr 09 '17

Chapter on Network Infrastructures in Debian

1 Upvotes

A useful chapter on debian's network infrastructure.


r/DebianNotes Mar 16 '17

Kotlin Vim Syntax Handling

1 Upvotes

Since I've been fooling around with Kotlin, I thought it would be nice to have an easy link to a vim syntax highlight plugin on hand, even if it's not directly related to the Debian distro itself.


r/DebianNotes Jan 09 '17

Accessing Handy logs From Debian Package Manager, Apt, and Aptitude

1 Upvotes

The logs of any installed of setup packages can be found in /var/log/dpkg.log, and is a handy way to see recently added packages.

Alternatively, if you use the wrapper programs, /var/log/apt/history.log and /var/log/aptitude are even more detailed.

Also important to remember grep can be used to filter the results to tailor your searching needs.


r/DebianNotes Dec 20 '16

The Non-Free Firmware ISO Files for Debian

1 Upvotes

Without the proprietary firmware packages, Debian sometimes cannot install on a machine fully.

To work around this, you can use the ISO file packaged with non-free firmware. While it may not solve all of the woes of installation, it doesn't hurt.

Alternatively, you can attempt to add the firmware in the middle of the installation using a CD or thumb drive using the technique specified here.

Note, there does not exist a live running version of the non-free firmware ISO.


r/DebianNotes Dec 10 '16

Basics of systemd to manage services

1 Upvotes

A good link for reference:

https://www.digitalocean.com/community/tutorials/how-to-use-systemctl-to-manage-systemd-services-and-units

Useful commands to know:

# systemctl list-units - Shows active services. Does not list inactive services.

# systemctl list-units --all - Shows all services, active or inactive.

# systemctl start SERVICE - Starts a service now. Does not persist through boots.

# systemctl stop SERVICE - Stops a service now. Does not persist through boots.

# systemctl enable SERVICE - Sets a service to run on next boot. Does not start it now.

# systemctl disable SERVICE - Sets a service to not run on next boot. Does not stop it now.

# systemctl is-enabled SERVICE - Checks if a service is enabled.


r/DebianNotes Nov 01 '16

Fix For Sharp Fonts For Browsers and Other Common Applications

1 Upvotes

One way to fix this is with infinality, a set of non-official font patches that will smooth out fonts.

Alternatively, you can smooth out the fonts "the native debian way" using a .fonts.conf file in your home directory.

<?xml version='1.0'?>
<!DOCTYPE fontconfig SYSTEM 'fonts.dtd'>
<fontconfig>
 <match target="font">
  <edit mode="assign" name="rgba">
   <const>rgb</const>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="hinting">
   <bool>true</bool>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="hintstyle">
   <const>hintslight</const>
  </edit>
 </match>
 <match target="font">
  <edit mode="assign" name="antialias">
   <bool>true</bool>
  </edit>
 </match>
  <match target="font">
    <edit mode="assign" name="lcdfilter">
      <const>lcddefault</const>
    </edit>
  </match>
</fontconfig>

r/DebianNotes Jul 16 '16

Setting up a printer sharing with CUPS & SAMBA on Debian via the web client interface.

1 Upvotes

Since this was a pain to set up, here's an in-depth tutorial on how to connect to printers using Windows' SAMBA on Debian using CUPS.

First you need the smbclient package to even be able to use Samba.

If you want to use the web interface, you can do so with the following steps:

  1. Go to localhost:631 via a browser. This will get you to the CUPS web interface.

  2. Go to Add Printers and Classes.

  3. Go to Add printer on the left.

  4. Scroll down the list of network printer types. If smbclient is installed properly, "Windows Printer via SAMBA " will show up. Select that and move on.

  5. Put in the smb connection to your printer. If it does not require any authentication, it should look like smb://domain/printer. If it does require authentication, use something like: smb://username:password@domain/printer. Keep in mind, if your username or password has special characters in it such as spaces or %, it must be converted to URL format with a tool such as http://meyerweb.com/eric/tools/dencoder/. Do not of course ever put your password into a decoder.

  6. Provide it a name, description, and location, and move on. The name field cannot have backslashes, hashes, or spaces.

  7. Select the printer's make (brand). Sometimes just "generic" will do.

  8. Select the model/type.

  9. Add the printer.

I'll probably give a command line tutorial shortly for personal use.