Showing posts with label console. Show all posts
Showing posts with label console. Show all posts

Sunday, March 15, 2026

Privacy, telemetry, data collection

https://librewolf.net/

LibreWolf — privacy enhanced Firefox gets much better results on https://coveryourtracks.eff.org

sudo apt update && sudo apt install extrepo -y

sudo extrepo enable librewolf && sudo extrepo update librewolf

sudo apt update && sudo apt install librewolf -y

Any program that uses web UI via web-server may leak internal LAN IP-address of the device, for example IP Webcam for Android does this in Referrer. F12 > Dev Tools > Network > check what requests app makes. Any API is potential channel for leaking user data. Be cautions when using proprietary apps in sensitive environment. FOSS is better in such cases, else decompile, modify, rebuild.

https://www.privoxy.org/user-manual/quickstart.html

https://docs.searxng.org/

sudo ufw enable

sudo apt install tor

torsocks --version

sudo systemctl enable tor      // start on boot

sudo systemctl start tor          // start now

sudo systemctl status tor       // check if running

torsocks curl https://check.torproject.org

CLI browsers are not safe browsers. Using w3m/lynx to “avoid JS” doesn’t make sense for anonymity; you’re trading usability and security for terminal UI. CLI inside a Tor-based system is safe way: Whonix, Tails (easiest).

Ordinary goofy will say that he has nothing to hide, but he do not take into account regime change, idiotic laws and limitations that may be in future... The less data you share, the better. Nobody has right to poke nose in your LAN, hardware, behavior, business...

Tuesday, March 3, 2026

Shrink disk size partition in terminal with parted resize

The Victory Lap: 851GB shrinked drive (Stable), 323GB 4256-sector slop (Webcam Trash), screaming shrinked 978GB 2005-sector zombie (Torrent Sacrifice). Successfully built "Post-Apocalyptic" Storage Array out of pure e-waste. It's chatty, it spams errors - but it's moving 110MB/s and cost $0.

Monday, March 2, 2026

KGet download and upload limit not working

nano ~/.bashrc

alias slowget='aria2c -c -x 16 -s 16 --file-allocation=prealloc --max-download-limit=1024K -o'

source ~/.bashrc

cd /desired/folder

slowget "file_0.avi" "URL"


If download fails:

slowget "file_0.avi" "NEW_URL" // to resume


Alternatives for using KGet:

E: Package 'trickle' has no installation candidate


sudo apt install firejail // 28.5 MB

firejail --net=eth0 --bandwidth=kget:1500:1500 kget


sudo wondershaper eth0 1500 1500 // NIC limit

Thursday, January 29, 2026

mpv - best light video media player for Linux

mpv file1.mp4 file2.mp4

mpv /path/to/folder/

mpv --playlist=my_list.m3u


Play/Pause: Space or p

Fullscreen: f (or Esc to exit)

Seek: Left / Right arrows (5 seconds) or Up / Down arrows (1 minute)

Volume: 9 (decrease) and 0 (increase)

Subtitles: j to cycle through subtitle tracks; v to toggle visibility

Audio: # to cycle through audio tracks

Quit: q (to close) or Q (to save the current position for the next time you open the file)


View Playlist F8 (opens an on-screen overlay)

Next File > or Enter

Previous File <

First/Last File Shift + Home / Shift + End

Loop Playlist Map L to cycle-values loop-playlist inf no in input.conf


3 videos

mpv --lavfi-complex="[vid1][vid2][vid3]hstack=inputs=3[vo];[aid1][aid2][aid3]amix=inputs=3[ao]" input1.mkv --external-files="input2.mkv;input3.mkv"


2 videos

mpv --lavfi-complex="[vid1][vid2]hstack[vo];[aid1][aid2]amix[ao]" input1.mkv --external-file=input2.mkv


2x2 grid (4 IP cams)

mpv --lavfi-complex="\

[vid1][vid2]hstack[top]; \

[vid3][vid4]hstack[bottom]; \

[top][bottom]vstack[vo]" \

"URL1" \

--external-file="URL2" \

--external-file="URL3" \

--external-file="URL4"


Several IP webcams in one window

mpv http://192.168.1.10:8080/video

i

fps: 25


mpv \

--no-correct-pts --container-fps-override=25 \

--lavfi-complex="[vid1][vid2]hstack[vo]" \

"http://192.168.1.10:8080/video" \

--external-file="http://192.168.1.10:8080/video"

Wednesday, January 28, 2026

cmus - Console Music Player for Linux command line

Shift + C, R to play playlist in loop.

Tab to focus cursor on playlist name * default

:clear into the command line at the bottom of the screen to empty playlist.

y to add selected folders or tracks to playlist

+ - to change volume

p - change track position down

1 2 3 (Playlist) 4 5 (Browser) 6 7 (Keybindings)

:set resume=true - resume playback from current position (don't work as expected)

:quit - exit and close player

https://github.com/cmus/cmus/blob/master/Doc/cmus-tutorial.txt

Saturday, January 17, 2026

Scanning HDD surface test on Linux

To scan the surface of a hard disk drive (HDD) for bad sectors in the Ubuntu terminal, the most direct command-line tool is **`badblocks`**. It performs a thorough surface scan by reading (and optionally writing) to every block on the drive.

Friday, January 16, 2026

smartctl do not show all SMART parameters for USB-drive

smartctl often shows fewer or limited SMART parameters for USB-connected drives (external HDDs/SSDs in enclosures or via adapters) compared to internal SATA/NVMe drives. This happens mainly because USB drives use a bridge chip (USB-to-SATA or USB-to-NVMe) that translates commands between USB (typically SCSI-based) and the internal drive's ATA/NVMe protocol.

Monday, June 2, 2025

Ubuntu GRUB not loading - boot manager repair

1. Check if Linux is in MB BIOS. Del or F11 and choose boot priority: 1. Ubuntu, 2. Windows.

2. If no GRUB (GRand Unified Bootloader), boot Linux from MB boot menu F11.

3. No boot from /boot/efi partition? Boot from USB drive > Try Kubuntu.

Sunday, June 1, 2025

Local ChatGPT alternative AI models

https://huggingface.co/mradermacher/LLama-3-8b-Uncensored-GGUF

https://huggingface.co/TheBloke/CapybaraHermes-2.5-Mistral-7B-GGUF/resolve/main/capybarahermes-2.5-mistral-7b.Q5_K_M.gguf

https://huggingface.co/TheBloke/Nous-Hermes-Llama-2-7B-GGUF/resolve/main/nous-hermes-llama-2-7b.Q5_K_M.gguf

Thursday, May 23, 2024

rsync backup synchronization script

cd /home/user/

mkdir .backup

touch folders.txt // include folders in column folder1 folder2 folder3

touch backup.sh

#!/bin/bash


# Define the source and destination base directories

src_base="/media/user/disk1"

dest_base="/media/user/disk2/backup"


# Define the list of folders to copy

folder_list="folders.txt"


# Define the rsync options, including --delete to remove files not present in the source

rsync_opts="-rahP --inplace --info=progress2 --stats -u --delete"


# Loop through each folder in the list

while IFS= read -r folder; do

    # Check if the folder path is not empty

    if [ -n "$folder" ]; then

        echo "Processing folder: $src_base/$folder => $dest_base/$folder"

        # Perform the rsync operation

        rsync $rsync_opts "$src_base/$folder/" "$dest_base/$folder/"

    fi

done < "$folder_list"

chmod +x backup.sh

./backup.sh

cp -ruv /home/user/ /media/user/disk2

Monday, August 21, 2023

Check proxy server on Kubuntu Linux

curl -v -x 136.144.178.240:80 http://www.google.com

*   Trying 136.144.178.240:80...
* Connected to 136.144.178.240 (136.144.178.240) port 80 (#0)
> GET http://www.google.com/ HTTP/1.1
> Host: www.google.com

Thursday, October 20, 2022

Use console command from bash history

history !n // then Home, delete 'history', edit command and Enter

history n // n === number

history | grep nvidia

history

Wednesday, October 19, 2022

rsync remote and local file copying command

Copy and overwrite older files only while showing progress:

rsync -rahP --info=progress2 --stats -u /source/folder/'My Folder'/ /destination/folder/'My Folder'/

    --existing              skip creating new files on receiver
    -u, --update            skip files that are newer on the receiver


Ctrl + Z => stop rsync process // -P => (-rahP)

Resume rsync process // fg %[number] – resume job [number]

fg 1 rsync -rahP --info=progress2 --stats -u /source/folder/'My Folder'/ /destination/folder/'My Folder'/


jobs – list the current jobs
fg – resume the job that’s next in the queue
fg %[number] – resume job [number]
bg – Push the next job in the queue into the background
bg %[number] – Push the job [number] into the background
kill %[number] – Kill the job numbered [number]
kill -[signal] %[number] – Send the signal [signal] to job number [number]
disown %[number] – disown the process(no more terminal will be owner), so command will be alive even after closing the terminal.

Cleanup after failed rsync:
find -type f -iname ".*.*.??????" -ls
find -type f -iname ".*.*.??????" -delete
https://www.tectut.com/2021/11/how-to-pause-and-resume-rsync/
https://manpages.ubuntu.com/manpages/trusty/man1/rsync.1.html
https://unix.stackexchange.com/questions/117190/best-way-to-sync-files-copy-only-existing-files-and-only-if-newer-than-target

Tuesday, September 27, 2022

grep command in Linux

grep string filename: Search for and display lines of filename that contain occurrences of string. 

grep string -r --exclude-dir={media,proc,sys} //  recursive search in  / excluding certain dirs

Saturday, August 13, 2022

find command in Linux

sudo find /folder -xdev -name file*

// -xdev means exclude other mounted file systems

// find -xdev doesn’t descend into directories that are mount points, but it still lists them

find / -xdev -size +100M // find files more than 100MB

find /home -name name.txt

sudo find / -xdev -name "file-name*" -print -exec rm -rf {} + / find and remove

find /path/to/directory -type f -name "*word*" //find files with a specific word in their name

//-type f: Limits the search to files (ignoring directories)

Wednesday, August 11, 2021

Check HDD SMART parameters in Ubuntu console

sudo apt install smartmontools

sudo fdisk -l

sudo smartctl --all /dev/sda

sudo smartctl --all /dev/sda1

sudo smartctl --all /dev/nvme0n1

Friday, July 2, 2021

Linux Console Tutorial Commands for beginners

This document is intended to provide a foundation of skills for using Linux in console or shell mode. The reader is not expected to have any prior knowledge of how Linux works, although in this case the reader should at least look through Linux Concepts and Running Commands before moving on to the Command Reference. The Command Reference introduces the core set of Linux commands categorized by the type of functionality they provide. The final section on Advanced Features illustrates several techniques that will help you get the most out of Linux.