Linux - Reddit – Telegram
Linux - Reddit
761 subscribers
4.18K photos
207 videos
39.8K links
Stay up-to-date with everything Linux!
Content directly fetched from the subreddit just for you.

Powered by : @r_channels
Download Telegram
USB mic makes constant click

When I use any usb microphone, everyone on the conference call hears a constant clicking, about 2 a second. It doesn’t matter if I’m speaking or not, although my voice seems to drown out the clicking.

Ubuntu 20.04 now, but I’m 99% sure 18.04 did it also. I tried a couple different usb mics.

Analog microphone works fine, so that’s what I’m using now.

https://redd.it/ku9d70
@r_linux
Any laptop brands to stay away from as a Linux user?

I am in the search for a new laptop and when googling I find a few recommendations on which brands to purchase a computer from as a Linux user.
Now I wonder, is there any list out there of brands to stay away from? Brands where the computers often do not work well with Linux?

https://redd.it/kuc5mu
@r_linux
New pacman parallel download. installing five apps in 10 seconds
https://asciinema.org/a/Dkr5ocECp6dV294KVD8CopvzC

https://redd.it/kuf9z0
@r_linux
Hoe to add bitlocker encryption like thunar from xfce to kubuntu?

Hi guys so xubuntu or manjaro xfce comes with thunar file manager and it has inbuilt support for bitlocker. I tried installing thunar on kubuntu but bitlocker support is not there. What packages I am missing? And no I dont want to do manual mount and decryption using dislocker.

https://redd.it/kug00y
@r_linux
What DE or distro is eaisiest to customise for elderly people and what customisations would you recommend?

By DE i mean desktop environment, i would like to know just incase i see any elderly people who struggle to use their windows system and would like spmething simpler, preferbly lightweight as thier computers are either from the windows xp days or £200 celeron laptops

https://redd.it/kum43x
@r_linux
WSL 2 or a virtual machine ?

I finally upgraded my laptop, but it has a new AMD processor and Nvidia graphics card. So I will be keeping Windows 10 for now. However, I would like to continue running a bitcoin node and lightning node. I have only ever installed these via linux systems. Would it be possible in WSL 2 to do this?

Thanks for any insights.

https://redd.it/kusmm7
@r_linux
SUCCESS: iPhone 7 with dead NAND netbooting unmodified Ubuntu 20.04 arm64 over usb gadget ethernet

I just got done with this incredible experiment, and I couldn't resist sharing.

EDIT: VIDEO!!! **https://youtu.be/DrntxWqDuvI**

\--------

Prerequisites

1. writable directory available over nfs, including dhcp server on local network
2. checkra1n 0.10.2-beta (get at https://checkra.in/releases/0.10.2-beta#all-downloads)
3. Kernel fork for h9x/A10 (https://github.com/corellium/linux-sandcastle)
4. projectsandcastle utilities (https://github.com/corellium/projectsandcastle)
5. EITHER arm64 cross compiler or an arm64 native device. I used a rpi4 on 20.04 <-- way helpful to be able to chroot and setup, otherwise you'd have to use qemu-user
6. Bridge setup noscript/udev rules by me https://github.com/newperson1746/iphone7-linux-nfsroot

1. Rootfs setup

Make sure you have debootstrap. I'm assuming an arm64 native ubuntu device already running to which you have mounted the nfs directory at /mnt/nfsrootarm64

`sudo debootstrap focal /mnt/nfsrootarm64`
Now you can chroot into it and run some important pre-setup:
I'd install nano for convenience, I'll assume you have it from now on
apt install nano network-manager openssh-server
`dpkg-reconfigure locales`
This'll fix the famous debootstrap LC_ALL error. I chose en_US.utf-8 and also chose it as default.
`dpkg-reconfigure tzdata`
Here you can fix the clock
`adduser <someuser>`
This'll be your non-root admin user for regular use
`adduser <someuser> sudo`
nano /etc/apt/sources.list
Add focal-updates, focal-backports, and focal-security!
You can also add universe if you want to at this point

2. Kernel setup

clone the sandcastle kernel, and make hx_h9p_defconfig , now we need to make quite a few changes to the config. I did them manually by editing .config:

CONFIG\_USB\_ETH=y
CONFIG_NFS_FS=y
CONFIG\_IP\_PNP=y
CONFIG_IP_PNP_DHCP=y
CONFIG\_BLK\_DEV\_INITRD=n // (none needed, otherwise it'll complain about wanting one)
CONFIG_CMDLINE="earlycon=hx_uart,0x20a0c0000 console=tty0 root=/dev/nfs rw nfsroot=<your_nfs_server_ip>:/nfsrootarm64,vers=4,tcp init=/usr/bin/systemd rootwait ip=dhcp g_ether.host_addr=12:a5:cf:42:92:fd g_ether.dev_addr=5e:bc:ca:27:92:b1 g_ether.idVendor=1317 g_ether.idProduct=42146 mitigations=off"
Replace the MAC addresses if you'd like, but I'll assume these are the ones moving forward
Fill in your nfs server ip
All of the flags are needed, I spent like 30 power cycles figuring out why nfs wouldn't mount unless i specified tcp.
CONFIG_ROOT_NFS=y
CONFIG\_CMDLINE\_FORCE=y
CONFIG_DEBUG_INFO=n // to speed up compile drastically

Now you can export LOCALVERSION if you'd like, and CROSS_COMPILE and ARCH=arm64if needed, but now it's just the good old:

make -j 4 Image

Now run `./dtbpack.sh` to generate the device-trees that PongoOS will use later.
lzma -z --stdout arch/arm64/boot/Image > ../Image.lzma to create the linux image that PongoOS can boot

3. Project Sandcastle utilities: clone the repo and cd to loader.

`make` will fail so simply run manually `cc -O2 -Wall load-linux.c -lusb-1.0 -o load-linux`
(-lusb was before load-linux.c, which broke sometime after sandcastle was first released)

4. Networking setup: clone my repo.

edit [`ethbridge.sh`](https://ethbridge.sh) with your ethernet ifname (it can trivially be modified to accept it as an argument from udev or something like that, but I'm lazy)
Place it somewhere static so you can call it from udev later
edit `70-iphone7.rules` with the MAC of your `g_ether` if you changed it, and put the correct path to [`ethbridge.sh`](https://ethbridge.sh)
SUCCESS: iPhone 7 with dead NAND netbooting unmodified Ubuntu 20.04 arm64 over usb gadget ethernet

I just got done with this incredible experiment, and I couldn't resist sharing.

**EDIT: VIDEO!!!** [**https://youtu.be/DrntxWqDuvI**](https://youtu.be/DrntxWqDuvI)

\--------

**Prerequisites**

1. writable directory available over nfs, including dhcp server on local network
2. checkra1n 0.10.2-beta (get at [https://checkra.in/releases/0.10.2-beta#all-downloads](https://checkra.in/releases/0.10.2-beta#all-downloads))
3. Kernel fork for h9x/A10 ([https://github.com/corellium/linux-sandcastle](https://github.com/corellium/linux-sandcastle))
4. projectsandcastle utilities ([https://github.com/corellium/projectsandcastle](https://github.com/corellium/projectsandcastle.git))
5. EITHER arm64 cross compiler or an arm64 native device. I used a rpi4 on 20.04 <-- way helpful to be able to chroot and setup, otherwise you'd have to use qemu-user
6. Bridge setup noscript/udev rules by me [https://github.com/newperson1746/iphone7-linux-nfsroot](https://github.com/newperson1746/iphone7-linux-nfsroot)

**1. Rootfs setup**

Make sure you have debootstrap. I'm assuming an arm64 native ubuntu device already running to which you have mounted the nfs directory at `/mnt/nfsrootarm64`

* `sudo debootstrap focal /mnt/nfsrootarm64`
* Now you can `chroot` into it and run some important pre-setup:
* I'd install nano for convenience, I'll assume you have it from now on
* `apt install nano network-manager openssh-server`
* `dpkg-reconfigure locales`
* This'll fix the famous debootstrap LC\_ALL error. I chose en\_US.utf-8 and also chose it as default.
* `dpkg-reconfigure tzdata`
* Here you can fix the clock
* `adduser <someuser>`
* This'll be your non-root admin user for regular use
* `adduser <someuser> sudo`
* `nano /etc/apt/sources.list`
* Add focal-updates, focal-backports, and focal-security!
* You can also add universe if you want to at this point

**2. Kernel setup**

clone the sandcastle kernel, and `make hx_h9p_defconfig` , now we need to make quite a few changes to the config. I did them manually by editing .config:

* CONFIG\_USB\_ETH=y
* CONFIG\_NFS\_FS=y
* CONFIG\_IP\_PNP=y
* CONFIG\_IP\_PNP\_DHCP=y
* CONFIG\_BLK\_DEV\_INITRD=n // (none needed, otherwise it'll complain about wanting one)
* CONFIG\_CMDLINE="earlycon=hx\_uart,0x20a0c0000 console=tty0 root=/dev/nfs rw nfsroot=[<](https://172.16.13.1)your\_nfs\_server\_ip>:/nfsrootarm64,vers=4,tcp init=/usr/bin/systemd rootwait ip=dhcp g\_ether.host\_addr=12:a5:cf:42:92:fd g\_ether.dev\_addr=5e:bc:ca:27:92:b1 g\_ether.idVendor=1317 g\_ether.idProduct=42146 mitigations=off"
* Replace the MAC addresses if you'd like, but I'll assume these are the ones moving forward
* Fill in your nfs server ip
* All of the flags are needed, I spent like 30 power cycles figuring out why nfs wouldn't mount unless i specified tcp.
* CONFIG\_ROOT\_NFS=y
* CONFIG\_CMDLINE\_FORCE=y
* CONFIG\_DEBUG\_INFO=n // to speed up compile drastically

Now you can export `LOCALVERSION` if you'd like, and `CROSS_COMPILE` and `ARCH=arm64`if needed, but now it's just the good old:

`make -j 4 Image`

* Now run `./dtbpack.sh` to generate the device-trees that PongoOS will use later.
* `lzma -z --stdout arch/arm64/boot/Image > ../Image.lzma` to create the linux image that PongoOS can boot

**3. Project Sandcastle utilities: clone the repo and cd to loader.**

* `make` will fail so simply run manually `cc -O2 -Wall load-linux.c -lusb-1.0 -o load-linux`
* `(-lusb` was before `load-linux.c,` which broke sometime after sandcastle was first released)

**4. Networking setup: clone my repo.**

* edit [`ethbridge.sh`](https://ethbridge.sh) with your ethernet ifname (it can trivially be modified to accept it as an argument from udev or something like that, but I'm lazy)
* Place it somewhere static so you can call it from udev later
* edit `70-iphone7.rules` with the MAC of your `g_ether` if you changed it, and put the correct path to [`ethbridge.sh`](https://ethbridge.sh)
*
Move `70-iphone7.rules` to /etc/udev/rules.d
* `sudo udevadm control --reload`

**5. checkra1n:** you'll need **0.10.2-beta** due to a command in PongoOS that was removed in later versions. It was added back after its open-sourcing, but the linux loader fails, so let's stick to this one.

\-----

**PUTTING IT ALL TOGETHER**

* Have the iPhone in recovery mode
* Launch checkra1n normally (no args)
* Hit start, and follow the DFU instructions. Once it tells you you've successfully entered DFU mode (sometimes it doesn't, just verify by `dmesg -w` in another terminal window reporting `Apple Mobile Device (DFU mode)` ), immediately CTRL-C before it starts attempting to boot into iOS.
* Now, run `checkra1n -cpE`
* This will launch PongoOS' command line only
* Now run `load-linux <path to Image.lzma> <path to dtbpack>`

Sit back and watch the iPhone show the two Tuxs on the top, autoconfigure DHCP, mount rootfs, and start systemd and go to a login prompt!

You should be able to ssh into it by checking what ip lease it was given by your dhcp server. Or, add a manual assignment by MAC address so you know exactly what it will be, as the bridge to ethernet exposes the usb-gadget's own MAC to the LAN, and it'll be visible independently from the tethered computer.

\-----

To be honest, I felt a lot of pride in using Linux for one of its classic purposes: repurposing otherwise-unusable devices. This iPhone would never be able to boot iOS again, as its nvme nand is completely dead. Yet, it boots Linux and mounts a filesystem over USB ethernet no problem!

**Go Linux!**

EDIT 3: Apparently they struggled to get Android to run because A10 mandates 16k page sizes, yet on mainline distros, there's no problem...

**Credits**

[https://blog.project-insanity.org/2020/04/22/linux-with-wayland-is-now-running-on-iphone-7/](https://blog.project-insanity.org/2020/04/22/linux-with-wayland-is-now-running-on-iphone-7/)

https://redd.it/kux9xx
@r_linux
Linux is the most "vulnerable" OS in the world.

I'm training for Cyber Security and we had a live class yesterday. The instructor asks us, "What's the most vulnerable OS in the world?"

Most people say Windows (predictably), I wanted to say "Any OS which hasn't been hardened & left at default config" but I didn't wanna be a smart ass - no one likes a smart ass. That's probably what the instructor is going for anyways. Trick question and whatnot.

Nope. The man claims it "Linux" which is the most vulnerable OS in the world. Shares this article.

I skim through the thing - we're live, don't have much time. I raised three concerns with the "analysis".

1. Debian is treated as one single OS, disregarding versions. Windows versions are treated separately.
2. Desktop Windows is represented by 7 & 10, which came out in 2008 & 2015 respectively. Windows XP, Vista, 8 & 8.1 are not even mentioned. This is for the period 1999-2019.
3. The analysis only considers raw No. of reported Vulns. without regard to severity.

The instructor does apologise... for offending me! Are my concerns valid? Are my objections justified? Am I thinking in the right way for a career in Cyber Security? No, it's whether or not I'm "offended" that's of top concern!

I'm a bit pissed and wanted to rant.

https://redd.it/kuy69p
@r_linux
Cron job



i need to schedule a cron job to get system time, cpu utilization and processor count and write it to an html and Schedule it for every 15mins.

Can anybody help me with this?

(Job automation using cron in unix/Linux)

https://redd.it/kuxzx9
@r_linux
What happened to Parler just shows us that we should not be trusting cloud servers like AWS with our business servers and data.

AWS cancels Parler contract for political reasons and gives them only 2 days to relocate.

The reason was political, but who knows what future nonsense reasons these companies may come up with to give you the boot. I hope many companies are now rethinking their cloud strategies and realizing they are gambling their whole business model on the whims of other companies. I think its time for some of these companies to start hiring Linux professionals to in-house more of their core business server needs.

Linux has made the opportunity to do this much easier in the past few years. I hope that Apple (of which I am NOT a fan) has shown us and that ARM and other CPU architectures have a place in the data center now. Chip manufacturers need to get their butts in gear to scale up these chips for more than just phone & tablet requirements. Data centers (both in-house and commercial) are going to need low power and cost CPUs that can handle greater memory and disk usage.

https://redd.it/kuywwc
@r_linux
It takes a very long time to unmount my hard disk.

I copied over 500GB and clicked unmount but it takes long time(still going on)(over 1h).

What shoud I do?

&#x200B;

hard disk:

seagate 2tb backup plus

&#x200B;

system:

cpu: amd r5 2600

ram: 12GB

gpu: gt1030

m/b: asrock a320m hdv r4.0

os: manjaro gnome 20.2.1

&#x200B;

pls help me ASAP!!!

https://redd.it/kv21mn
@r_linux
Reversed the Z3 series LCD display USB protocol as I use Linux
https://redd.it/kv4m8u
@r_linux
I made a tool for remembering linux commands

I always forget some linux or osx commands (like sudo lsof -iTCP -sTCP:LISTEN -n -P for checking which ports are being listened on). So I created this command, saves me a trip to google every time. It stores your own commands in a json file in you home dir. It can also fill in arguments in an interactive way, like the message in the example below. Feel free to use.

https://github.com/lvoogdt/ehh

https://i.redd.it/us0pbeldqqa61.gif

https://redd.it/kv7r5u
@r_linux