Try ‘apt –fix-broken install’ with no packages

This is an annoyed issue, but after several tries, here is my approach for the fix:

sudo dpkg --configure --force-overwrite -a
# or
sudo apt -o Dpkg::Options::="--force-overwrite" --fix-broken install
Add to my src(0)

No account yet? Register

Ubuntu Zoom Virtual Background without physical green screen

Virtual background in zoom is indeed a great feature, but unfortunately it doesn’t work on Ubuntu without a physical or real green screen. So here are some steps and commands you could run and make it work. (I use this on Ubuntu 20.04 but basically it should work for Lubuntu, LinuxMint, Debian or other systems as well as everything is via docker)

First install docker if you haven’t got it on your system already: https://leftsidemonitor.com/install-docker-and-docker-compose-on-linux/

Then run the following commands to install some required libraries

sudo apt install v4l2loopback-dkms;
sudo modprobe -r v4l2loopback;
sudo modprobe v4l2loopback devices=1 video_nr=20 card_label="v4l2loopback" exclusive_caps=1;

Now let’s clone this repo: https://github.com/leftsidemonitor/ubuntu-zoom-virtual-background, and run everything via docker

# Clone
git clone https://github.com/leftsidemonitor/ubuntu-zoom-virtual-background.git ~/ubuntu-zoom-virtual-background
cd ~/ubuntu-zoom-virtual-background
cp docker_defaults.env .env

docker-compose up &;	

When you don’t want to use the webcam anymore, let’s stop it

cd ~/ubuntu-zoom-virtual-background; 
docker-compose down &;

Let’s also add some aliases some next time you can run and stop this much faster as well

# add to ~/.bashrc or ~/.zshrc 
alias fakecam='sudo modprobe -r v4l2loopback;sudo modprobe v4l2loopback devices=1 video_nr=20 card_label="v4l2loopback" exclusive_caps=1;cd ~/ubuntu-zoom-virtual-background; docker-compose up &;'
alias stopcam='cd ~/ubuntu-zoom-virtual-background; docker-compose down &;'

That’s it, let us know if you manage to get it working in Zoom and other video calling software as well.

Add to my src(0)

No account yet? Register

Install Yarn on Debian/Ubuntu

curl -sS https://dl.yarnpkg.com/debian/pubkey.gpg | sudo apt-key add -
echo "deb https://dl.yarnpkg.com/debian/ stable main" | sudo tee /etc/apt/sources.
sudo apt update && sudo apt install --no-install-recommends yarn
# If you want to install yarn along with nodejs, use the following command
# sudo apt update && sudo apt install yarn
yarn --version
Add to my src(0)

No account yet? Register

Install Mongodb server on Debian / Ubuntu

sudo apt-get install gnupg
wget -qO - https://www.mongodb.org/static/pgp/server-4.4.asc | sudo apt-key add -
echo "deb http://repo.mongodb.org/apt/debian buster/mongodb-org/4.4 main" | sudo tee /etc/apt/sources.list.d/mongodb-org-4.4.list
sudo apt-get update
sudo apt-get install -y mongodb-org
sudo systemctl daemon-reload
sudo systemctl start mongod
sudo systemctl status mongod
sudo systemctl enable mongod

sudo systemctl stop mongod
sudo systemctl restart mongod
Add to my src(0)

No account yet? Register

Use locate command to find files in Linux

locate is a very useful command, which can be use from time to time to find files in Linux when we don’t know where that file is.

sudo apt update
sudo apt install locate
sudo updatedb # need to let sometime for this to finish 
locate .bashrc # locate can be called from anywhere 
locate -c "*thingtosearch" # search by regex, show count
locate -e "*thingtosearch" # search in real-time, regardless db not updated.
locate -i "*thingToSearch" # search and ignore case
locate -S # view locate db                                                           at  10:56:54
Database /var/cache/locate/locatedb is in the GNU LOCATE02 format.
Database was last modified at 2020:10:07 10:38:37.467600124 +0200
Locate database size: 5860142 bytes
All Filenames: 464048
File names have a cumulative length of 34300427 bytes.
Of those file names,

	1317 contain whitespace, 
	0 contain newline characters, 
	and 32 contain characters with the high bit set.
Compression ratio 82.92% (higher is better)
Add to my src(1)

No account yet? Register

Install Midori browser using Terminal

Midori is probably one of the most lightweight browser for Linux, sometimes we just need it to quickly search for text information on Google and this is the browser for that purpose.

sudo apt update
sudo apt install midori
midori
Add to my src(0)

No account yet? Register

Install and use Vagrant on Linux for development

sudo apt-get autoremove virtualbox-dkms
sudo apt-get install build-essential linux-headers-`uname -r` dkms virtualbox-dkms
sudo modprobe vboxdrv
sudo modprobe vboxnetflt

Install and use vagrant

sudo apt update
sudo apt install curl
curl -O https://releases.hashicorp.com/vagrant/2.2.10/vagrant_2.2.10_x86_64.deb
sudo apt install ./vagrant_2.2.10_x86_64.deb
## Let's test 
vagrant --version
mkdir vagrant-project
cd vagrant-project
vagrant init centos/8

## If you already have a vagrant image.box
vagrant box add mybox ./image.box
vagrant init mybox
vagrant up
## To ssh into vagrant box
vagrant ssh
## To stop vagrant box
vagrant halt 
## To destroy and clean up everything
vagrant destroy
Add to my src(0)

No account yet? Register

Lightshot alternative for Linux

Flameshot is a very good screenshot app, works seamlessly like Lightshot on Windows, let’s install it the easy way:

## Install using apt
sudo apt update
sudo apt install flameshot
## Quickly bind Print (Prtsc) to flameshot
gsettings set org.gnome.settings-daemon.plugins.media-keys screenshot '[]'
gsettings set org.gnome.settings-daemon.plugins.media-keys custom-keybindings "['/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/']"
gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/ name 'flameshot'
gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/ command '/usr/bin/flameshot gui'
gsettings set org.gnome.settings-daemon.plugins.media-keys.custom-keybinding:/org/gnome/settings-daemon/plugins/media-keys/custom-keybindings/custom0/ binding 'Print'

Add to my src(0)

No account yet? Register

Install Docker on Linux using Terminal

sudo apt-get update
sudo apt-get install \
    apt-transport-https \
    ca-certificates \
    curl \
    gnupg-agent \
    software-properties-common
 
 curl -fsSL https://download.docker.com/linux/ubuntu/gpg | sudo apt-key add -
 sudo apt-key fingerprint 0EBFCD88
 sudo add-apt-repository \
   "deb [arch=amd64] https://download.docker.com/linux/ubuntu \
   $(lsb_release -cs) \
   stable"
 sudo apt-get update
 sudo apt-get install docker-ce docker-ce-cli containerd.io
 sudo systemctl enable docker
 sudo docker run hello-world
 sudo groupadd docker
 sudo usermod -aG docker $USER
 newgrp docker
 docker run hello-world
Add to my src(0)

No account yet? Register