Recent Questions - Unix & Linux Stack Exchange |
- Can it possibly work if I assign two shells to SHELL in cron?
- Execute command and output stdout when specific file is read
- Snap in Pamac CLI
- Strange uncontrollable scrolling
- Recover Windows from Grub Rescue - No partition active
- Debian 8.0 Not working after installation in vm
- How do I set-up a PKI certificate-based SSH login in a REHL8 Virtual Machines
- Get all directories with only one specific file inside
- i cant grep tmux ls output when no server is running
- What's the difference between GNOME, KDE, and XFCE? [closed]
- How to redirect the output of a pipe to >/dev/null
- Service hosted as daemon unreachable
- Prevent the second command from starting in the bash pipe if the first command fails
- VM boots with wrong keyboard layout
- BREW ERROR : compinit:503: no such file or directory: /usr/local/share/zsh/site-functions/_brew_cask
- cannot open '/home/user/original/AndroidManifest.xml' for reading: No such file or directory
- How do i get python to tail a logfile? Tried various methods
- How do I stop memory issue caused by baloo_file_extractor?
- How to pin a package in dnf (Fedora)
- Problem with phpmyadmin
- Force linker to find stdc++ library in non-standard directory
- Understanding network problem (syslog)
- Convert video to exactly the same format as another video
- Why not use "which"? What to use then?
- Text to yaml conversion
- XML parsing using xmllint and customizing the output
- How to delete a line containing pattern which is first found after a specific pattern
- how to compare two xml files having same data in different lines?
| Can it possibly work if I assign two shells to SHELL in cron? Posted: 10 Jul 2021 10:37 AM PDT Recently I started the process of gradual switching my shell to nu and because of it I thought about assigning its path to SHELL in cron. Having read a good part of the manual at It does not work, the scripts from my crontab are not doing their job. Whereas either Can I assign two shells to SHELL? Does it even make sense to do so? |
| Execute command and output stdout when specific file is read Posted: 10 Jul 2021 10:29 AM PDT I want a file to contain the output of a command whenever it is read. For example, when I read (or copy) This may not be possible, but considering the unix philosophy of "Everything is a file", and considering the fact that anything from the raw bytes of a partition to the process list a file, would there be any way to achieve this (on Linux specifically)? I could obviously run a cron job every hour that automatically updates the file, or mess around with pacman config options or compile pacman with my own modifications, but those implementations would be tedious and not that elegant. Any ideas? |
| Posted: 10 Jul 2021 10:30 AM PDT is it possible to manage snap packages on the cli with |
| Strange uncontrollable scrolling Posted: 10 Jul 2021 09:08 AM PDT I woke up this morning to this strangeness. It was not doing this when I left my computer yesterday. I first noticed it when my tmux key bindings did not work. My prefix is Ctrl+Space. Then I noticed when my mouse went over my browser tabs they continuously scrolled to the right. Then I noticed terminal always scrolled to the bottom. But not inside my vim sessions, and only inside tmux. Then I also noticed that any browser frame which contains text wider than the frame and has a horizontal scroll bar, it will scroll to the right. Also holding my Ctrl key inside my browser continuously zooms it out. What I have done to troubleshoot:
If it happens without my mouse on, and without my keyboard plugged in, it has to be outside the devices I would think
My question is, how can I troubleshoot this? Is there a way to see some unknown key strokes happening? Or a stuck mouse wheel command? |
| Recover Windows from Grub Rescue - No partition active Posted: 10 Jul 2021 08:28 AM PDT I had a dual boot Windows and Ubuntu. I wanted to get rid of the Ubuntu. So during the clean-up process I ended up with Grub-resuce (I deleted the linux partitions from my Windows). I only have a bootable Ubuntu USB. I followed this link to fix the Grub rescue - https://unix.stackexchange.com/a/71634/53123 However, now I am getting "No partition active" How can I fix this and recover my Windows without losing the data? |
| Debian 8.0 Not working after installation in vm Posted: 10 Jul 2021 08:03 AM PDT |
| How do I set-up a PKI certificate-based SSH login in a REHL8 Virtual Machines Posted: 10 Jul 2021 07:03 AM PDT Do I need 3 virtual machines to do so? One for CA, Client and server? Is there a full and complete guide for doing so? It seems like every article insist on having some sort of requite knowledge. Thank you! |
| Get all directories with only one specific file inside Posted: 10 Jul 2021 06:11 AM PDT I have a series of directories on a remote server (D1, D2, D3,...) and each directory contains multiple files (f1, f2, f3) with the same names. What I have on the remote Server: What I want on the local machine: I need to get all directories with only f1 inside (D1/f1, D2/f1, D3/f1,...). I know SFTP doesn't support regular expressions but is there an alternative way to do that? If that's not possible in SFTP, is there a way to do it using scp or rsync? |
| i cant grep tmux ls output when no server is running Posted: 10 Jul 2021 05:12 AM PDT what im trying to achieve:
when tmux server is alive so i can grep that output, correct? grepping that output:
i chose good. now checking if the server is offlinefirst i need to kill the server: easy now check if server is alive using normal output, as expected butif i want to grep that output when server is dead, check this strange thing out:
meaning that grep another testcase of thing strangeness its always priting when catting the file: nothing there i need to find a way to check if server is running or not in order to update my zsh prompt with that informationNOTE: variable any help guys? thanks in advance. |
| What's the difference between GNOME, KDE, and XFCE? [closed] Posted: 10 Jul 2021 09:42 AM PDT What's the difference between GNOME, KDE, and XFCE? I know KDE's lighter than GNOME, but I don't know what XFCE has to offer. I am most concerned about performance, as in speed, but a few features would be nice as well. I'm on Ubuntu 21.04, with a Intel Core i3 4020y - not great :| Thanks! |
| How to redirect the output of a pipe to >/dev/null Posted: 10 Jul 2021 05:18 AM PDT I would like to redirect the STDOUT and STDERR of the whole pipe to Considering this is my command: I know this is the wrong way of doing it: How can we achieve that since simply adding |
| Service hosted as daemon unreachable Posted: 10 Jul 2021 05:14 AM PDT I recently hosted an API as a daemon service but I am unable to curl to Below is the entire nginx config file I created for this particular API. So internally when I check the |
| Prevent the second command from starting in the bash pipe if the first command fails Posted: 10 Jul 2021 06:39 AM PDT After learning (more or less) some useful discussions about pipes like Get exit status of process that's piped to another and Exit when one process in pipe fails I still can't avoid starting the second command when the first command fails. Am I missing a fundamental detail about pipes? So for example shouldn't create the almost empty |
| VM boots with wrong keyboard layout Posted: 10 Jul 2021 07:31 AM PDT Question edited, please keep in mind when reading the comments below. I use VMware Workstation Player to run my Linux VMs. Starting from the boot and during GRUB menu, LUKS password entry, and initial user login screen, the keyboard appears to be set to US. This is source of errors when entering passwords as I have a French Swiss keyboard (QWERTZ). The system uses the correct keyboard layout (CH-FR) only after the user has logged in. How can I set the correct keyboard locale on a CentOS 8 Stream VM so that it is applied since the boot? This is the output of I found this answer for Ubuntu, but it references a UEFI system. My VM uses BIOS. Is there a way to do so that does not require UEFI? |
| BREW ERROR : compinit:503: no such file or directory: /usr/local/share/zsh/site-functions/_brew_cask Posted: 10 Jul 2021 05:22 AM PDT I recently got this error: I didn't install anything new. I just updated the brew using "brew update" command. The next time I updated the terminal my Oh-My-Zsh theme was gone. So I checked the I uninstalled and reinstalled Homebrew but still the same problem. What should I do? UPDATE(Solved): I found out that it was an issue with the symlinks. I used the following command |
| cannot open '/home/user/original/AndroidManifest.xml' for reading: No such file or directory Posted: 10 Jul 2021 08:49 AM PDT I've been trying to use evil-droid to backdoor an apk. But it showed me this error. Please someone help me!! I've been searching for a solution for hours now!! |
| How do i get python to tail a logfile? Tried various methods Posted: 10 Jul 2021 06:01 AM PDT I'm trying to get python to tail a logfile e.g. syslog. I've tried opening the file in read mode, but it never realises if another process writes to the file. Using a popen, and actual 'tail -f' together with registering the popened process to select, python is able to read any writes. And using the python systemd module, i can get systemd to respond with the contents, but I'd like to know if there are other ways instead of these methods and, why the opening a file for reading and constantly trying to read 1024 bytes, doesn't work. |
| How do I stop memory issue caused by baloo_file_extractor? Posted: 10 Jul 2021 06:29 AM PDT I using Arch Linux with XFCE/XFWM4. The default FM is very lightweight thunar, but I installed dolphin for some more functionality. I was studying about large files and creating some 2 gigs of files on my system. I suddenly saw my system is going wild where But every time I create a big file, I see On the other hand, I haven't used dolphin for weeks now. Why does it daemonize baloo when dolphin is not in use? Apart from uninstalling |
| How to pin a package in dnf (Fedora) Posted: 10 Jul 2021 08:53 AM PDT I've got a temporary situation where I'm working with pre-release F27, and need to keep one package to a specific (working) version and not be upgraded until the subsequent versions stop breaking something. I know in general "you don't really want to do this", but as I said, it's a temporary dealing with a pre-rel system. You can "pin" packages with the apt system, but I can't locate anything equivalent for dnf. |
| Posted: 10 Jul 2021 05:06 AM PDT When I type [Tue Jun 14 16:35:47.699632 2016] [:error] [pid 14660] [client 192.168.0.101:44854] PHP Fatal error: require_once(): Failed opening required '/usr/share/php/php-gettext/gettext.inc' (include_path='.:/usr/share/php') in /usr/share/phpmyadmin/libraries/select_lang.lib.php on line 477 |
| Force linker to find stdc++ library in non-standard directory Posted: 10 Jul 2021 07:02 AM PDT I've read a lot of guidance that says the I want So I add If I add: to my environment, there are no more linker errors. Yay, but that doesn't solve the problem. Users downstream aren't going to want to depend on this library being in the proper place. WHY ISN"T LD_LIBRARY_PATH BEING SEARCHED FIRST!?! |
| Understanding network problem (syslog) Posted: 10 Jul 2021 08:02 AM PDT I am running a lubuntu 14.04 server and its always worked well, except for the last couple of days it keeps dropping off the LAN. I am using a couple of powerlink adapters to connect it up as WiFi was never very solid on it. Anyway, I plugged a screen and mouse/keyboard into it to try to work out whats up with it, and I tailed the syslog. Here is an excerpt: http://pastebin.com/4ftXsai4 Can someone please give me any clues to what might the problem be? Or any tips on how to track down the issue. I have unplugged the Ethernet cable from my router and rebooted it all, to no avail. EDIT #1I'm not sure what happened. But the server has been up, connected all day today. I am tailing a log file via a remote SSH connection and its not disconnected once. Could have been that the WiFi card was playing up, or the router was struggling to assign DHCP, although, if it was a DHCP problem, why would it keep disconnecting? |
| Convert video to exactly the same format as another video Posted: 10 Jul 2021 09:07 AM PDT Suppose I have two video files A and B. Now I want to convert A to the same format (i.e. same container, same audio and video codec), same bitrate, size etc. as B. Is there a way to do this automatically (i.e. without extracting the information manually and giving it manually as input parameters) using a command line tool (or even a GUI tool)? |
| Why not use "which"? What to use then? Posted: 10 Jul 2021 06:07 AM PDT When looking for the path to an executable or checking what would happen if you enter a command name in a Unix shell, there's a plethora of different utilities ( We often hear that |
| Posted: 10 Jul 2021 09:17 AM PDT I have a tab separated text file in this format: and I'd like to use awk to convert this to yaml: So far my awk script looks like this But I can't figure out how to get each field from line 1 onwards to print after it's header and then recreate the yaml key values from the first line of the input file. In the real file there are 38 fields and 34 records (so not huge). |
| XML parsing using xmllint and customizing the output Posted: 10 Jul 2021 09:59 AM PDT I have xml file (say input.xml) of the following schema: I need to parse this file and write the output to another file. The required output should be of the following form: What I have got so far is: This gives me o/p of the form: How should I go about getting my required output instead of this current o/p? |
| How to delete a line containing pattern which is first found after a specific pattern Posted: 10 Jul 2021 10:03 AM PDT I am writting a shell script to delete an entry from a specific group. eg: file name is I want to delete an entry from above file (filename is dest.xml) with Is there any simple way to this this? |
| how to compare two xml files having same data in different lines? Posted: 10 Jul 2021 10:23 AM PDT I have two files have same data but in different lines. File 1: File 2 : If I use But I need to get no difference, because these files having same data in different lines. |
| 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