The Problem
What's happening here, is that you've installed rust utilities via rustup: cargo, rustc, etc. The problem is, these utilities cannot find the default rust 'toolchain', as it has not been configured yet.
The Fix
This is a very simple fix. The following command:
rustup default stable
In this case, you want to change stable to be whatever release channel you're on. For nightly rust, this would switch to
rustup default nightly
Sunday, October 29, 2017
Saturday, October 7, 2017
[Fix]: No Audio in Linux / Videos Don't Play
The Problem
There exists an especially frustrating problem on some linux distributions where audio will simply not play. The lack of audio playing can mean that you're also not able to watch videos, even completely without audio! Most recently, I installed Ubuntu 17.04 to find that I was unable to listen to music or even watch Youtube videos with subtitles. That's untenable, and a complete deal-breaker for most people (for obvious reason).
The Explanation
So, what's really happening here is that your user isn't in the audio group. Because they're not in the audio group, videos which contain audio (i.e all video file formats) are simply not allowed to play! Why users aren't de facto members of the audio group, especially on Linux, is completely lost on me. But, it's enough information to fix the problem thankfully.
(Optional) A Quick Rundown on Groups
For the uninitiated; Linux has two essential components of its security system: groups and users. Users are added to groups to give them certain privileges. So, since your user is NOT a member of the audio group, you cannot play audio.
The Fix
The fix for this couldn't be easier. You need to run the following command:
There exists an especially frustrating problem on some linux distributions where audio will simply not play. The lack of audio playing can mean that you're also not able to watch videos, even completely without audio! Most recently, I installed Ubuntu 17.04 to find that I was unable to listen to music or even watch Youtube videos with subtitles. That's untenable, and a complete deal-breaker for most people (for obvious reason).
The Explanation
So, what's really happening here is that your user isn't in the audio group. Because they're not in the audio group, videos which contain audio (i.e all video file formats) are simply not allowed to play! Why users aren't de facto members of the audio group, especially on Linux, is completely lost on me. But, it's enough information to fix the problem thankfully.
(Optional) A Quick Rundown on Groups
For the uninitiated; Linux has two essential components of its security system: groups and users. Users are added to groups to give them certain privileges. So, since your user is NOT a member of the audio group, you cannot play audio.
The Fix
The fix for this couldn't be easier. You need to run the following command:
sudo usermod -a -G groupName userName
Then, we're already half way done! You are now a member of the audio group.
To apply this fix, you *need* to shut down and power back up
For me, nothing actually applied this change other than a full shutdown / restart cycle. Even rebooting didn't actually do it for me, strangely enough. That goes against all of my intuition as an avid computer user and programmer. I can't explain it.
Once you've reboot, you should then be able to run the following command:
alsamixer
Then, hover over the columns which read 'MM' and hit 'm' to unmute them. Raise their volume to 100%. Your desktop environment will control the actual volume you here, but you don't want the underlying sound system to artificially lower your volume.
The Last Step
The final thing you have to do is to run the following command:
pavucontrol
Then, from here, set up whatever audio device you'll be using. In my case, with headphones plugged into the audio jack it wound up being 'Line Out'. Under the configuration tab, I needed to select Audio Stereo Duplex for it to work. I'm also unsure why the Audio Stereo Duplex configuration works, but I know it does.
You're Done!
After all of this, you should have working audio. As you can tell, the rumor that Linux audio can be a headache is proven to be true. Videos should already be working. If you are still having trouble with it, leave a comment below and I'll do my best to help out.
Subscribe to:
Posts (Atom)