Usually, a docker container has a way to easily switch to root account.
It can be as easy as 'su root' or even root by default when you run a shell such as 'bash' within it.
However, sometimes, it's not that easy. You need to work hard for it.
My issues where the following:
su command won't work as it's just a symlink …
Sometimes, you may need to know which container a volume is associated with.
Use this command:
1docker ps -a --filter volume=VOLUME_NAME_OR_MOUNT_POINT See https://stackoverflow.com/questions/42857575/how-to-determine-what-containers-use-the-docker-volume
Sometimes, you would like to know what your input credentials in browser. Do the following via Google Chrome Developer Tools:
1Chrome DevTools > Network > Fetch/XHR > login > Payload where login refers to something like https://api.myproject.local/v1/login
If you are seeing this error:
1~# nmap -Pn www.example.org 2Starting Nmap 7.80 ( https://nmap.org ) at 2020-09-04 20:59 UTC 3Couldn't open a raw socket. Error: Permission denied (13) Most probably, installation was through Ubuntu's snap as follows:
1~# snap install nmap 2nmap 7.80 from Maximiliano Bertacchini …
Use the following command:
17z a -p -mem=AES256 -tzip file.zip source-file1.txt source-file2.txt It will ask for a password but will obviously not be echoed.
17za e file.zip You need to install as well associated tools. Shown are for Redhat-like Linux:
1sudo yum install p7zip p7zip-plugins Some details …
I turned-off my built-in wireless network interface using the command:
1iwconfig wlan0 txpower off Howerver, I can no longer turn-it back on. Logic says just change "off" to "on" but instead, I get this error.
1root@raspberrypi:/home/pi# iwconfig wlan0 txpower on 2Error for wireless request "Set …
I did buy a wifi donggle in Lazada but I didn't know if it can be detected in my Raspberry pi using Rasbian. Command to use: lsusb. Example:
1root@raspberrypi:/home/pi# lsusb 2Bus 002 Device 001: ID 1d6b:0003 Linux Foundation 3.0 root hub 3Bus 001 Device 003: ID 148f:7601 Ralink Technology, Corp. MT7601U Wireless …
When a pi gets under voltage below 4.63V (+/-5%), a thunderbolt icon is shown in the monitor like in https://www.raspberrypi.org/documentation/configuration/warning-icons.md It will then get throttled to get back to desired voltage.
From command line, here's what you can use to check:
1vcgencmd get_throttled with some …