New answers tagged

0 votes

systemd shutdown what does -h mean when combined with --halt?

"Halt" was the original operation; it would stop the OS, but wouldn't turn off power, as most computers at the time didn't even have soft power-off. After such an ability was added to PCs, ...
user avatar
  • 370k
0 votes

How do you use regular expressions with the cp command in Linux?

To copy 100 log files into another log2 folder of same directory, I use following cp app.log.[0-9][0-9] log2
user avatar
0 votes

How to use zsh in flatpak vscode

This is how I personally got it working on my vscode, FYI terminal.integrated.shell.linux was deprecated: "terminal.integrated.defaultProfile.linux": "bash", "terminal....
user avatar
  • 1
2 votes

Why and how does Rufus use FAT32 for a bootable Linux ISO?

There are many things to unpack here. First, how does a Live Linux boot anyway? Unlike a regular installed-to-disk Linux, it does not use an ext4 (or similar) file system on a disk partition. Instead, ...
user avatar
  • 53.2k
0 votes

Get output of remote command locally

Use the -t before the command like so: ssh remote_host -t "ls > /tmp/file_on_remote_host.txt" More info here https://www.mankier.com/1/ssh#-t
user avatar
1 vote

keep each line containing x only if column y is the first containing x. remove the rest containing x

So, I went this route, which is nice and simple and seems to be working for me: awk -F, '!x[$4]++' A far as I can tell, awk here is checking the 4th column (field), if it's not seen it before, then ...
user avatar
4 votes

Why and how does Rufus use FAT32 for a bootable Linux ISO?

CDs and DVDs use ISO-9660 or UDF, not FAT32 or ext4, otherwise most non-Linux platforms can't read them. But modern Linux installation discs are also isohybrid so they can also boot directly if the ...
user avatar
  • 23k
0 votes

How to call a script from udev rule as non-root user?

I found the following solution/workaround, in called script I added the following command before rsync call. Seems to work good. su - <UserName> -c "rsync -hvrstc /copy/from /copy/to"
user avatar
  • 13
0 votes

Make Thunderbird request certificate on port 993, not 443

I just ran into this as well while trying to connect to a locally run Dovecot server (that by default uses a self-signed certificate). Given that the TB interface to add certificate exceptions only ...
user avatar
0 votes

Is automount in linux dangerous as in windows

Automount is usually not dangerous, but there are some risks and attack surface involved: Once your device is mounted, your Desktop Environment will start mining the filesystem for media files, the ...
user avatar
1 vote
Accepted

Copying a whole system from an sd card to another

Just copying files from a logical partition to another does not make the target device bootable. If you want to clone a card, clone the whole device, not just files on a logical partition. For example ...
user avatar
  • 1,424
0 votes

ps: How can i recursively get all child process for a given pid

If we want to see all the children and all subchildren of a process the first answer doesnt work. The first answer assumes that all children and subchildren have the same session id. It is wrong. An ...
user avatar
  • 101
0 votes

Change one .json key value with an already existing one using jq

This should work: jq '{id: .name}' input.json
user avatar
  • 430
0 votes

Self-signed certificate with stunnel on linux

I had the same issue recently, after a client's client-certificate expired and they provided a new one to replace it. I should have realized the source of the problem because the error changed from ...
user avatar
-1 votes

How to enter login information for a website from the linux command line

to access quicker to your login url web without remembering username or password #make a script below echo "username" |xclip -sel clip |chromium-browser (input url address for login here ...
user avatar
0 votes
Accepted

What kind of SSL shall I use in an Apache web server for serving clients only connected via VPN? Is it enough to use self-signed certificate?

Yes, you / your comments are correct, you already have a secure connection via VPN, so there is no need to encrypt the data between webserver and browser as well. It would be enough to just use HTTP. ...
user avatar
  • 7,589
1 vote
Accepted

Manually sending ARP packets using bash

This can't be done with the bash shell but with a dedicated command run from a shell. On Linux arping is the dedicated command for this. Example, on a system with a single network interface (so ...
user avatar
  • 4,163
0 votes

Why do I get a “Connection to [host] closed by remote host” error over SFTP connection?

I had this issue on a chroot SSH login. I solved it by increasing log level in /etc/ssh/sshd_config: LogLevel VERBOSE Then I restarted sshd and watched the log file while connection attempts were ...
user avatar
0 votes

How to connect to Oracle database on AWS EC2

If you want to add another layer of security. SSH or DMZ + Load Balancing is the way to go. If not Make sure the following are all open for the IP. firewall, VPC Network, AWS inbound outbound rules.
user avatar
0 votes
Accepted

How to change the default application for a certain file extention on Linux?

The application has no "*.desktop" file Then create one. You can put custom .desktop files in ~/.local/share/applications/ and they will show up in the same list together with system-wide ...
user avatar
  • 370k
1 vote
Accepted

Failed to run curl 7.83.0 on alpine

Have you try an apk update and apk upgrade to fix missing librairies ? As describe here the issue came from missing librairies on you alpine distribution. bash-4.3# apk update bash-4.3# apk upgrade ...
user avatar
  • 26
0 votes

How can I install redis server 7 on Ubuntu 22.04?

sudo add-apt-repository ppa:redislabs/redis sudo apt-get update sudo apt-get install redis
user avatar
  • 31
0 votes

How can I check whether rsync transfered files or not?

This is a brittle solution, but I really don't like running rsync in a subshell, nor capturing its output, both have made things difficult for me to debug in the past. So when I need this, what I do ...
user avatar
  • 145
0 votes

The requested security information is either unavailable or cannot be displayed

The error "The requested security information is either unavailable or cannot be displayed" is also shown on a fully patched Windows 10 when your file extension has a space as the last ...
user avatar
  • 1,168
0 votes

Cant play music or youtube videos on arch linux

I had this problem because I had both Pulseaudio and Pipewire packages installed. I completely removed Pipewire and disabled it's systemd services. Made sure all required Pulseaudio packages were ...
user avatar
  • 560
2 votes

Can you run an exe file made with linux on windows

I compiled a c file on my linux machine and named it test.exe, is it possible to run that file on windows? The answer is simple: no, for at least two reasons. (This answer assumes that the Windows ...
user avatar
  • 16.4k
0 votes

Can you run an exe file made with linux on windows

I looked up a few C examples that said they were compiled in Linux. I looked for examples that had no special Linux functions or hooks. If that is the case and the source code is bland, standard C,...
user avatar
  • 35.2k
1 vote

A cross-platform way to share a USB device over a network?

If you are open to NOT use a RaspBerry PI and use a ready-made solution: There exist networked USB hubs. A small device with 1 or more USB ports and a RJ45. Accompanying software is installed on a ...
user avatar
  • 27.7k
1 vote

A cross-platform way to share a USB device over a network?

It is possible to run Windows in a virtual machine, and to pass a USB device through to it from the physical host. This avoids having to dedicate a machine / hardware to Windows (the VM can be shut ...
user avatar
2 votes

A cross-platform way to share a USB device over a network?

Linux has usbip built in, and there seems to be a Windows port of the vhci driver for USB-IP client systems. (Note that this is not the same usbip-win project as the other usbipd-win project suggested ...
user avatar
  • 370k
0 votes

Samba recycle module is not moving deleted files as desired

We had excactly the same problems here. It worked out, that it was a permission-issue. It seems that the recycle-module runs with the user-account who actually deleted the file, thus it can be that ...
user avatar
0 votes
Accepted

pfSense VPN to Debian with NAT for DMZ

This would only solve half of the problem, so I need some kind of NAT from the VPS to my pfSense, so that everything incoming from the internet to specific ports on the VPS will be routed (through the ...
user avatar
  • 370k
0 votes
Accepted

Unable to replace faulty harddrive to rebuild the Raid 1 Array (intel RST Raid 1)

So I answering my own question for everyone's benefit who has to deal with these type of fake raid controllers. Here is what I found Interestingly the md126 is not the main RAID array here, it is ...
user avatar
  • 11
1 vote

Files copied from Windows samba share to Linux file system does not retain date modified metadata

I think a more apropriate tool would be rsync with -av switch. To see what "metadata" is available: you could throw something like exiftool at the images. And this is probably a timely ...
user avatar
  • 65
0 votes

How can I open a veracrypt volume without mounting it? (Ubuntu 16.04)

it seems to be possible in veracrypt to create the (decrypting) device mapper without mounting using the "--filesystem none" parameter
user avatar
1 vote

Files copied from Windows samba share to Linux file system does not retain date modified metadata

Therefore the issue must be that the Linux command cp does not even try to retain date modified data when copying files from Samba shares. No, the issue is that the Linux command cp doesn't try to ...
user avatar
  • 370k
0 votes

ZSH npm/node/nvm command not found after installing OhMyZSH

just add nvm or node in your plugins: plugins=(git nvm) reboot ur terminal. Then, good to go
user avatar
0 votes

Downloaded software wont launch itself and has to be opened with existing application (Xarchiver)

What you normally download may be packages eg *.deb *.rpm etc? Files labelled *.tar.xz are compressed archives, which is why your system correctly wants to open it with Xarchiver. Do so and extract it,...
user avatar
0 votes

Disable Bitlocker with Linux

That was quick. Unfortunately, I can't do it from Linux but I can recover recovery keys from Hirens BootCD PE. I prepared a USB drive with Hirens from Linux. I formated a USB drive to FAT. Mount ...
user avatar
  • 279
5 votes

Translate reversed hostnames to regular hostnames from a file

You can use awk with a custom delimiter for that: <hostnames.txt awk -F. 'NF {print $2"."$1}' >output.txt Explanation: With <filename a file is passed to stdin "-F" sets ...
user avatar
  • 151
0 votes

Linux – cannot remove owned file with 777 permissions

Just for knowledge sake: I solved it using sudo editing the sudoers file: Cmnd_Alias MOVE = /bin/mv, /bin/rm user ALL=(postgres) NOPASSWD:MOVE In the procedure the user does:sudo -u postgres rm /tmp/...
user avatar
0 votes
Accepted

Ansible playbook runs from user, but not from crontab

I sort it out! First of all, I had to figure out how to generate some output from crontab job into a .log or .txt file, in order to have some clue on why this odd behavior. For that I used this answer....
user avatar
0 votes

what is "SI0CSIFFLAGS: Operation not permitted"?

Had same error running Metasploit in Kali. Issue was that I was logged in as the kali user and this user didn't have permissions. Once I switched to root $ sudo su and then ran Metasploit # msfconsole,...
user avatar
  • 101
0 votes

Passing udev environment variables to systemd service execution

To extend the great answer by @Ben Campbell.. Here's how to access a property from the udev environment database after a device triggered the udev rule. Say for instance a USB drive was just attached ...
user avatar
0 votes

Why my udev rule does not work in my Fedora PC?

I think I found a solution after some search. First of all, in udev rules is necessary to add ATTR{partition}=="1" to avoid multiply calls of the script. The second and the most important, ...
user avatar
  • 13
0 votes

Samsung SSD 980 PRO capping out at 510MB/s

Your SSD doesn't have a SATA mode. It can ONLY run on NVMe, which your motherboard supports in that M.2 slot with any combination of PCIe cards with a 3rd Gen Ryzen CPU (as you have). (You can also ...
user avatar
  • 27.7k
1 vote
Accepted

How to recover corrupted btrfs partition that nothing can read

Assuming that you don't have a recent backup to restore: I would dd image the entire drive now, and work on a copy of that image. (If it's hardware failing, then you don't want to be thrashing it.) ...
user avatar
  • 65
18 votes

chown - Operation not permitted even as root user

exfat doesn't support file ownership. There's no place to record it in the bits being stored on the USB drive, so Linux gives you an error when you attempt to change them. Try mounting with uid=1000,...
user avatar
0 votes

NFS Permission Denied when mounting from WSL

I have the same issue, but have a few possible solutions. My nfs logs look like this (I'm guessing yours do, too): cat /var/log/syslog: refused mount request from 192.168.123.123 for /mnt/poolio/data (...
user avatar
10 votes

What does `tar: Cannot connect to …: resolve failed` mean?

Format your date so it doesn't break tar. date +"%Y-%m-%d" would work.
user avatar
  • 484

Top 50 recent answers are included