Recent Questions - Unix & Linux Stack Exchange |
- Display Constantly "Fuzzy" with Nvidia Driver
- How to get the normal username as a variable
- How to extract pairs of values from a file and echo them to an output file
- Create a secure configuration file for zsh scripts
- Files are corrupted when accessing files from host OS and the passive device on a virtual USB driver
- How to create a system user on WSO2 with readonly access to the LDAP server?
- How do I install debian manually in Termux?
- Salt size in /etc/shadow
- How to make a Linux distribution? [closed]
- Is access to root isolated from software knowing the password?
- Bad Internet Causes Bad Local SSH connect
- Can't open serial port via minicom, but fine via Python and shell
- Tools for batching N commands over L scripts (for N≫L)?
- Install 'top' and 'find' on stripped a down debian linux with apt-get install?
- Adding second IP to RHEL 8 virtual machine
- sed regex fails to capture the entire paragraph containing the pattern
- HP 1/8 G2 medium changer not detected in Oracle Linux 8
- How can I profile virtual memory accesses made in user mode and kernel mode?
- Dual boot (Ubuntu)-(Ubuntu with boot partition on usb)
- How to lock fan speed for amd gpu in Ubuntu 20.04?
- Filter script output during runtime
- Can't format USB storage at /dev/sdb
- Using netcat and curl together in a bash script
- How to get persistent (permanent) smb mount using kerberos authentication on RHEL7?
- How to show the host name in Linux commandline prompt
- SELinux is preventing /opt/google/chrome/chrome-sandbox from write access on which file?
- Passing named arguments to shell scripts
- How can I reduce a video's size with ffmpeg?
Display Constantly "Fuzzy" with Nvidia Driver Posted: 17 Aug 2021 12:33 PM PDT I've been having this issue for at least 3 years where my display will be blurry while using the proprietary Nvidia driver. Nouveau doesn't fix anything either. Any screenshots that I take using the monitor will show up crystal clear, but visually looking at it, everything seems fuzzy, blurry and sometimes even ghosts if I move a window around. I have a second monitor plugged in via a DP->VGA adaptor and, even when my main monitor is blurry, that looks perfectly fine. Sometimes my monitor will work flawlessly, but that's once in a blue moon. I'm currently running Void Linux with the latest Linux kernel and KDE Plasma. I am using an Nvidia RTX 2060, and the monitor is getting the signal via HDMI. I am unsure of the monitor's control board and anything like that as it's a seemingly random brand that have no official datasheets (and it doesn't even seem to be sold anymore). What I do know is it's a 32" 1080p@60Hz display, and it won't go higher than that. I don't have this issue on Windows 10, and everything is displayed crisp and clear as day.
I have looked around for others that have experienced something similar to me and all of the issues turned out to be misconfiguration or things that had nothing to do with what I'm experiencing (mostly anti-aliasing issues). I find it hard to think of things that could be at fault as it works perfectly fine in Windows, which is baffling to me. I'm completely out of ideas now, so any help or insight as to how I'd go about even debugging this would be greatly appreciated! |
How to get the normal username as a variable Posted: 17 Aug 2021 12:23 PM PDT I'm trying to create a makefile script and I tried to automatically create multiple folders in a specific directory. However, I've had issues when trying to implement this: First, I tried doing it the normal route: However, it gave me this error: I then tried using the but then it'll be registered as |
How to extract pairs of values from a file and echo them to an output file Posted: 17 Aug 2021 12:20 PM PDT I have hundreds of language files that belong to a project. These files are like this How to process a file like this, using a bash script and extract the parts like and echoing/printing them to an output file? the elements I want have always this format NOTE: "another string" may contain accented chars. I want the output file to have just the pairs, one per line. How do I do that? |
Create a secure configuration file for zsh scripts Posted: 17 Aug 2021 11:10 AM PDT I want to store some default variables for a zsh shell script that I'm working on. I know that using a To ensure maximum compatibility for all of my users, is there a way using the tools available by default in zsh (on Amazon Linux 2, for specifics) to securely read lines from a text file and extract a set of preset variables from the config file? While I know the text file itself won't be hashed, that's not my issue. My goal is simply to avoid the possibility of someone inserting malicious code into the config file and having it processed by the script. |
Files are corrupted when accessing files from host OS and the passive device on a virtual USB driver Posted: 17 Aug 2021 10:55 AM PDT I am doing an experimental project to make a virtual USB device to transfer photos from a camera to a Linux computer. In this case, I am using a Jetson-nano board and Ubuntu as the operating system. I have prepared a FAT32 partition and configured it as a mass storage using USB gadget driver. Now the partition is visible as a mass storage for the Ubuntu system itself. Also, I connected a camera via OTG cable to save the images from camera to this storage. Images also getting saved and I wrote a program to copy the files from mass storage to the Ubuntu system after camera is done its job (by putting milliseconds and seconds level delays). I observed the images are getting corrupted when copying or accessing the files to get the size of the files from the mass storage. Also if I reboot the system, same image file can be seen correctly. Hence problem is happen when a program is trying to access the files in real time (while camera is saving the images to mass storage partition). with this use case, following things are happening.
functionality is working fine if
in this case I have following questions
|
How to create a system user on WSO2 with readonly access to the LDAP server? Posted: 17 Aug 2021 10:01 AM PDT I have two systems that include the identity server and application server. My application server needs to read the ldap information from the identity server. I can create a new super admin on the identity server via the deployment.yml file, however that will treat the new user as an admin user and thus giving write permission to the application server. And the application doesn't need write permission in order to sync the users. How would I create a system level user that only has read permission to the ldap server w/o modifying openldap manually? |
How do I install debian manually in Termux? Posted: 17 Aug 2021 09:56 AM PDT I want to know How can I install debian manually (step by step) in Termux without a third party shell script to avoid possible MITM attack? |
Posted: 17 Aug 2021 11:53 AM PDT After user password change the size of salt decreased in RHEL/Centos 6, eg: As you can see, FkMNsNxT is 8 characters. Why it happens? In the beginning, after installation, the size is 16 chars. |
How to make a Linux distribution? [closed] Posted: 17 Aug 2021 09:55 AM PDT I was just wondering how I can make my own Linux Distribution. Mainly what I'm looking for is more of a list of what I need to learn. Meaning what sites, or books I might have to look at. Of course anything helps though |
Is access to root isolated from software knowing the password? Posted: 17 Aug 2021 12:06 PM PDT I have seen that programs like sudo among other things can easily gain/give root access if you provide them with the password. Wouldn't that mean that any app can simply spoof (or guess if the password is simple enough, which in many cases can be the case for desktop users) the password as I type it in some other place, then use that to give root access to itself without me even knowing? |
Bad Internet Causes Bad Local SSH connect Posted: 17 Aug 2021 10:23 AM PDT I'm running into an issue that has me scratching my head a bit and can't seem to find the right information online to clear things up for me. networking has never been strongest subject, but hopefully, I'm reaching out to the right people for some guidance. My setup is farely simple, I have 1 client windows laptop that I use to SSH into a linux sever on the same network. Additionally, the laptop uses port forwarding for vnc. The issue I have is that, just today, I discovered that my internet quality seems to negatively affect my SSH connection (Bad Internet = bad ssh). I began randomly receiving disconnent errors when connecting to my server (network failure software caused abort). I've tried adjusting my tcp keepalives, but it still drops out. From my limited network understanding, since they are on the same network then any information sent/received from the client doesn't even make it all way down the stack and just looks at the destination IP and reroutes to the server's local IP. Is that a fair over-simplification? So, doesn't this sort of behave like a WLAN and should be independent of internet quality? If not, would I be able to make it independent of internet using the same router and not disrupt the existing network (other people use this wifi)? The goal is to to achieve a stable ssh connection on a WLAN that's performance is independent of internet speed. Also, the server doesn't necessarily need access to the internet but my laptop defenitely will (while connected to the server). Any input would be greatly appreciated. Thank you UPDATE 1: After running "mtr -4b google.com" from my linux server, I see the following performance metrics: Is there any red flags here? or is this typical? |
Can't open serial port via minicom, but fine via Python and shell Posted: 17 Aug 2021 10:04 AM PDT I have been having issues with connecting to serial ports via I also tried to setup a connection with I tried installing the latest system updates (I run Edit: I just got the idea to communicate directly via my shell, and this seems to be working. I therefore think it is a minicom issue. Still very strange, since I can't find other people with the same problem. |
Tools for batching N commands over L scripts (for N≫L)? Posted: 17 Aug 2021 11:33 AM PDT Let's say that I have access to a high-performance Linux cluster equipped with a scheduler (e.g. LSF, Slurm, etc.) that will allow me to have up to M jobs either running or pending at any one time, of which at most L < M can be running concurrently. Now, suppose that I want to run N independent commands as quickly as possible. If N ≤ M, I can just submit each command as a separate job to the scheduler, and be done with. But what if N > M? Or N ≫ M even? The N ≫ M scenario occurs extremely often in my line of work, so often in fact that a hope to find tools to facilitate dealing with it would not be unreasonable1. One very general and straightforward way to get around the scheduler-imposed limits is to split the N independent commands into L separate one-time "batching" scripts, and submit the latter to the scheduler, as L separate jobs2. Granted, creating such one-time batching scripts is a dull, somewhat annoying chore, but someone who is handy with their shell, or with a scripting language like Python, Perl, etc., can easily take care of it, and even home-roll their own hacks to automate it. My question is, however, are there publicly (and freely) available tools in the Unix ecosystem that can be used even by those with less programming skill to automate the chore of generating L such batching scripts, given as input a list of N independent commands? 1Actually, the scenario occurs so often that I am surprised that schedulers do not already have built-in support for it. At least the schedulers that I am most familiar with (Slurm and LSF) do not have any such support, as far as I can tell. Please correct me if I missed something. 2 More generally, one could to batch the N commands into k batching scripts, as long as k ≤ M, but, in my experience, choosing k = L is the most straightforward way to achieve a maximal, or near-maximal, throughput under these constraints. The reasons for this are not too difficult to see, but an adequate discussion of the matter would require more time than I want to take up here. |
Install 'top' and 'find' on stripped a down debian linux with apt-get install? Posted: 17 Aug 2021 12:16 PM PDT I have a docker image I'm extending and it has a stripped down version of Debian. I've already installed some packages with the initial Dockerfile push I did but I'm also wanting to install Also, I'm not sure how to find this info myself so if there is an easy way to figure it out that I could have done myself that info would be an awesome FYI to include. Output of running |
Adding second IP to RHEL 8 virtual machine Posted: 17 Aug 2021 12:00 PM PDT I have an existing RHEL8 virtual machine used for running httpd and a single virtualhost. I need to add a second IP/virtual host and am running into an issue. My understanding is that NetworkManager still parses network-scripts. The existing IP is configured as: I created a second script set up with the new IP: I then restarted NetworkManager with But I'm not seeing the new device named ens4 listed, just the existing IP (ens3) Device ens3 works fine. The existing bridge from the host machine works since device ens3 works fine (I can view site content, ssh to machine, ect). So I'm not super sure this is a VM host setup issue. What step(s) am I missing to add a second IP to RHEL8? Is the process different when the server is virtual? |
sed regex fails to capture the entire paragraph containing the pattern Posted: 17 Aug 2021 12:24 PM PDT I have this XML file (example) Using the However, it captures only this string: But I try to capture the entire first paragraph between What am I doing wrong here? |
HP 1/8 G2 medium changer not detected in Oracle Linux 8 Posted: 17 Aug 2021 12:29 PM PDT I have a HP 1x8 G2 Autoloader that connected to a SAN switch, on my VMware environment I have an Oracle Linux that should work with the tape. The problem is after connecting tape to VM, medium changer is not detected but tape drive is OK! I installed latest version of HPE Array Controller for Centos 8 and tape Autoloader was in Sequential mode which I changed it to Auto. kernel info: mtx outputs: |
How can I profile virtual memory accesses made in user mode and kernel mode? Posted: 17 Aug 2021 12:18 PM PDT I would like to generate a log of all virtual memory accesses performed in user mode and kernel mode as a result of running some program. Besides collecting memory access locations, I also want to capture other state information (e.g., instruction pointer, thread identifier). I anticipate that I won't be able to collect all of my desired statistics with any tool out of the box. I intend on doing this profiling off-line, so I'm not concerned about the performance impacts. In fact, depending on what is available, it would be helpful to know which tools can record all memory accesses and which can only sample. I was originally going to augment Valgrind's lacky tool until I realized that it only records user mode memory accesses. Looking into what other tools I might use, I'm at a loss at how I can quickly determine which tool is capable of capturing the information I want. Here are some resources I've found that have gotten me started: |
Dual boot (Ubuntu)-(Ubuntu with boot partition on usb) Posted: 17 Aug 2021 10:27 AM PDT I have two internal SSDs in my computer, one that currently has Ubuntu 20 installed with the following partitioning: That work's well with the default bootloader GRUB2 But I want to install a second Ubuntu 20 on my other drive with a detached boot partition (on an usb thumb). The second drive has the following partitioning : And I installed my boot partition on my USB as follows : When I install my second ubuntu with ubiquity from a live CD all works well (I can boot with my usb to my SSD) but when I update grub on the previous SSD (nvme0n1) because the previous configuration has been removed by the fresh installation I cannot boot anymore with my usb (but I can boot to the first SSD/nvme0n1) I tried to install the second ubuntu with or without an EFI partition, with or without a bootloader. But the main point is that when I update grub from the first SSD/nvme0n1 it's not detecting the second ubuntu (os-prober does not find my second OS even if I mounted it) The ideal situation for me would be to have my EFI and boot partitions on my usb with the rest of my second SSD in my computer, but I could also go for only my boot partition on a USB. |
How to lock fan speed for amd gpu in Ubuntu 20.04? Posted: 17 Aug 2021 12:16 PM PDT I'm trying to lock RPM of my AMD Radeon videocard fans at the full speed: What I have tried so farObviously, it doesn't work due to missing permissions (even with I have also tried
Neither does Archilinux Wiki states it should be possible though https://wiki.archlinux.org/index.php/fan_speed_control#Configuration_of_manual_control They edit values directly with Another guide also recommends configuring fans this way https://linuxconfig.org/overclock-your-radeon-gpu-with-amdgpu Python
Daemon (service) also doesn't work: To sum up: seems that I can't edit /sys/ amdgpu-related entries at all Part 2It seems that there has to be another way around, like some In Windows, it's possible to tune fans directly from the AMD Radeon driver GUI app. I don't want fancy curves, I'm simply trying to force lock static RPM (full-on mode). I'm using The question itselfI wonder if that's possible just to set update This thing works! But only for 1-2 seconds, after that, fans go back to system-defined speed update 2 Disabling pwm works for about 1-2 seconds. But after that, some daemon reverts this value back to 2. How could I prevent it from changing by other users except me? E.g. prevent it from changing by the system? |
Filter script output during runtime Posted: 17 Aug 2021 11:03 AM PDT I have a script that runs about 10 other scripts in the background that constantly generate new output. I would like to keep that initial script running and be able to simply type in it to filter all the output displayed on the terminal in real time. For the sake of simplicity let say each of these for loops represents one of my background scripts (The outputs contain color codes btw.): My first idea was to redirect all the output of the background scripts into a file and then use the But there are several issues with that. Update problem: The output won't update when the Color code problem: If I search for Disappearing input problem: Even if I'd manage to get new output to be printed in real time after hitting enter for a search, the user won't be able to type (or see, to be more accurate) his/her next search properly. I would like the filter text the user is typing to always be visible. Any ideas how this could be accomplished? |
Can't format USB storage at /dev/sdb Posted: 17 Aug 2021 10:55 AM PDT I have an 8GB USB storage and When trying to: I got: What to do? I'm on Ubuntu 18.04. |
Using netcat and curl together in a bash script Posted: 17 Aug 2021 12:04 PM PDT This question is more related to infosec, but I can't seem to find a workaround in automating the following process: There is a cURL command which triggers a connection to the netcat. Without automatization, I type in I am trying something like this in my bash script: The netcat starts a listener, goes into the background, the cURL triggers the connection (I receive the connection back), but the netcat immediately closes. If I remove the However, once I click 'enter', the netcat job gets suspended immediately: I have to |
How to get persistent (permanent) smb mount using kerberos authentication on RHEL7? Posted: 17 Aug 2021 11:28 AM PDT Environment: I have joined a few of my RHEL 7.3 boxes with MS AD domain using realmd/sssd. I have allowed only members of a few allowed groups can login to the box. Credentials caching is disabled. All works well without any problem. What I need to achieve next: I want one Windows SMB share to be permanently mounted to the Linux (in the fstab or else) using Kerberos(passwordless). What I have achieved so far: I am able to mount the Windows SMB path, but it expires when the manually generated TGT ticket expires. How I'm doing it: I generate TGT ticket using 'kinit' then TGT ticket for cifs mount using kvnp Then making an entry in the fstab with 'sec=krb5' and providing the uid of the desired service account. Using the above the SMB share is mounted successfully but expires in 9 hours upon expiration of the TGT ticket. Please suggest if there is something that I can do to make the mount permanent. Note: I'm not modifying the TGT ticket expiration time thinking it may cause some security or compliance concerns.(please, correct me if I'm wrong). |
How to show the host name in Linux commandline prompt Posted: 17 Aug 2021 11:10 AM PDT I have several VMs and right now my command-line prompt looks like ENV: CentOS/ssh |
SELinux is preventing /opt/google/chrome/chrome-sandbox from write access on which file? Posted: 17 Aug 2021 10:06 AM PDT I keep getting the following error ever since upgrading to Chrome
I have not installed any custom plugins or modified my Chrome settings. Various search on Google turns up bug reports being closed as not a bug, and instructions on how to bypass SELinux by applying custom policy. The SELinux troubleshooter suggested the following: I do not quite agree with the recommendation to turn off SELinux controls on Chrome Plugins. I also do not know what write access on file Can anyone explain what is the problem and how this issue can be resolved? |
Passing named arguments to shell scripts Posted: 17 Aug 2021 10:14 AM PDT Is there any easy way to pass (receive) named parameters to a shell script? For example, And inside Is this possible in Bash or Zsh? |
How can I reduce a video's size with ffmpeg? Posted: 17 Aug 2021 10:08 AM PDT How can I use I forgot to mention that when the video can use subtitles (*.srt or *.sub), I'd like to convert them too to fit the parameters of the converted video file. |
You are subscribed to email updates from Recent Questions - Unix & Linux Stack Exchange. To stop receiving these emails, you may unsubscribe now. | Email delivery powered by Google |
Google, 1600 Amphitheatre Parkway, Mountain View, CA 94043, United States |
No comments:
Post a Comment