Since our last dist-upgrade from Debian 8 Wheezy to Debian 9 Stretch, we’ve encountered quite a few new issues. By issues, I am referring to incompatibilities with any manual changes that I have made to my PC.
Most of the repositories that I have manually added have to be manually adjusted from wheezy to stretch. After that, we tried the usual sudo apt-get update and it never completed it’s course.
Stuck on 0% [Working]?
sudo apt-get install apt-transport-https
This one line solved the 0% Working issue where the package list downloading would hang and become stuck on Debian 9.
Only recently I found out Etcher.io didn’t make bootable Windows USB’s properly, or rather, did not support it at all.
There are 3 ways to make Windows Bootable USBs on Debian Ubuntu of any Linux distro, but first you’ll need a Windows ISO which Windows themselves now provide. Just search “Windows ISO” and make sure you’re at microsoft.com. At the time of writing, Windows was providing the Windows 10 ISO here.
1) Use WoeUSB on Ubuntu or Debian to make Bootable Windows USBs from ISO.
The deb packages for WoeUSB are found here, ignore the .exe files in this directory.
You’ll need to install VirtualBox (sudo apt-get install virtualbox) and then install a virtual Windows machine using the ISO from Microsoft.com at the start of this article.
You will also have to install VirtualBox Guest Additions to be able to passthrough the physical USB stick straight into the VirtualBox. To do that, boot your virtual machine, select Devices on the toolbar, and select insert Guest Additions CD. Install it, reboot, and you’ll now be able to connect your USB. To connect your USB, go to the virtual machine settings and add USB 2.0 or USB 3.0 support. You can only add USB support when the machine is off. If you haven’t installed the guest additions correctly, it will give you an error on booting.
If your VirtualBox doesn’t recognize the USB or fails to install drivers etc., make sure it’s formatted as Fat32 (use gnome-disks or gparted, might need to reformat it a few times with both programs).
When you boot the machine, bottom right of the virtual machine window has a small USB icon, right click it, and select the desired USB that you’d like to pass straight through to the VM.
Here is a screenshot of me successfully making a Bootable Windows USB using Rufus on a VirtualBox Windows 7 while my host OS is Debian.
3) Use another Windows PC to create the bootable USB.
Playing around with GRUB is a nightmare for the first few times, and often GRUB reinstallations will actually be mandatory when installing multiple operating systems on the same drive, or multiple drives, or after reinstalling windows or vice versa.
If you can’t boot into your OS, you’ll need a linux live CD of any kind (Debian or Ubuntu) or a rescue disc. The most natural way to reinstall GRUB is to boot into your main OS via a live CD and run the grub-install command. I prefer not to do this as my live CD is around 4GB and can take 5-20 minutes to create the USB. And if you don’t have your OS live CD laying around, you’ll need another PC to either download it and create the bootable USB (60 minute exercise at least), or you can use a smaller, lighter, recovery OS on a bootable USB.
It’s a tiny 20MB ISO that you can use Etcher to create a Super Grub2 Disk bootable USB in about 30 seconds. Any version will work. This will get you back into your PC. Once you’re inside you can run the grub-install command. On Debian this is the only command that worked for me completely:
Open gparted or gnome-disks and find the /dev/sdX of the drive you want to install grub to. Your main partition will be either /dev/sda or /dev/sdb or /dev/sdc or /dev/sd0. It should show that it’s mounted at / which is your root directory of the OS you’re in, you’re main OS.
Now reboot without the Super Grub2 Disk USB and see if your distro goes into GRUB. This is a good time to keep the Super Grub2 Disk in a safe place as it is a very powerful tool for booting into all sorts of drives or places, even ISOs with loopback setup.
How to use gparted live when your GRUB isn’t working with Super Grub2 Disk and when you only have one USB.
Now, here’s a challenge: rescue your linux computer with one USB.
Get Super Grub2 Disk as described above and boot into your normal OS via the above method. After you’re in your normal OS, download Rescatux but don’t burn it to a USB.
Instead, as root, open your boot folder and make a folder called boot-isos and put Rescatux in that folder.
Now when you boot using Super Grub2 Disk, you’ll see a bootable ISO entry with the Rescatux ISO which you can boot into! This is because Rescatux is setup for loopback mount meaning you can boot into it on a hard disk instead of a USB. Booting a live distro from live USB. Rescatux has gparted and you can make changes to your partitions without being mounted but Rescatux does not have grub-install. This helped me when I had one single USB but I wanted to use both “gparted live” and Super Grub2 Disk at the same time without losing my Super Grub2 Disk USB.
If you can’t copy and paste properly on Facebook without the comment or message becoming jumbled up, you may have to allow a certain Firefox setting in the about:config that allows clipboard events to function properly on Linux distros.
Open a new tab and type:
Double click on this entry to set it to true and copying and pasting correctly from the clipboard should function as expected now.
This fixed the issue for me when I could not copy and paste on Facebook messenger or comments on Firefox.
If you have WordPress sites on a VPS with less than 700mb-1gb of RAM, you may experience intermittent MySQL downtime as the service turns itself off when it exceeds your server or allocated resource usage.
The following commands will append to your crontab. This will check if mariadb/mysqld is running, if it’s not running, it will restart it.
If you have MySQL:
echo " * * * * * root /sbin/service mysqld status || service mysqld restart" >> /etc/crontab
If you have MariaDB:
echo " * * * * * root /sbin/service mariadb status || service mariadb restart" >> /etc/crontab
Click play on the video. Then right click on the video and inspect element.
Find <video class=”fp-engine”…. and copy the Akamai URL.
Alternatively click download on the video and once the download starts, cancel it, open your download queue and then right click on the download and copy the download URL.
With either of the above methods to get the URL (which lacks a .mp4 extension), you can use that in your cURL command as follows:
curl -o video.mp4 "paste long download URL here"
Remember to use double quotes “” around the URL.
The reason we use curl -o, instead of curl -O, is that the file name of the download will be something like 1200 characters long which gives us a File name too long error.
It will start downloading like this: [[email protected]]# curl -o video "http://wevideo-a.akamaihd.net/7hSWWXP2%Fcbhg1zZayqjvbARb73ozXljnFZxHPS2%9cLxLHznbxXZjSx9qbXyA3v1g7qan33FzqRno7vjljWbch1bygzqvz%zqqa%2LAjzLHXH9ASRXoPljgR1lZX9P2jWFXhacbyoq"
% Total % Received % Xferd Average Speed Time Time Time Current
Dload Upload Total Spent Left Speed
100 212M 100 212M 0 0 442k 0 0:08:11 0:08:11 --:--:-- 541k