date
int64
1,220B
1,719B
question_description
stringlengths
28
29.9k
accepted_answer
stringlengths
12
26.4k
question_title
stringlengths
14
159
1,431,359,411,000
AFAIK make was the beginning or grandfather of build-tools. It needs/needed .configure correctly done in order to spew out a binary tool/package etc. I just commented on node. I do remember using one tool which had a build progress bar on the CLI and performed perfectly but don't remember the name. Can somebody pleas...
A number of build tools offer progress information. CMake in particular produces makefiles which, by default, print out their progress: Scanning dependencies of target mikmod-static [ 1%] Building C object CMakeFiles/mikmod-static.dir/drivers/drv_AF.c.o [ 1%] Building C object CMakeFiles/mikmod-static.dir/drivers/dr...
What is the build-tools alternative to 'make' that has a progress bar?
1,431,359,411,000
I am trying to compile the linux kernel 5.15.64 but it fails. I have the config and use make -j4 && sudo make modules_install -j4 but this is the error I get. make[1]: *** [kernel/Makefile:160: kernel/kheaders_data.tar.xz] Error 127 make: *** [Makefile:1896: kernel] Error 2 What is going wrong in the process?
There is a bug report https://bugs.gentoo.org/701678 that has the same messages. This was caused by having CONFIG_IKHEADERS=m in your configuration and not having cpio available.
Error trying to compile kernel 5.15
1,431,359,411,000
I'm struggling to compile mkclean on Ubuntu 16.04. I download the file and extract it but when I run ./configure I get this: ./configure: 2: ./configure: %%BEGIN: not found ./configure: 3: ./configure: SCRIPT: not found ./configure: 4: ./configure: %%END: not found make: *** corec/tools/coremake: No such file or direc...
mkclean now uses CMake: tar xf mkclean-0.9.0.tar.bz2 cd mkclean-0.9.0 mkdir build cd build cmake .. make In older versions of mkclean, using autoconf, the configure script needs to be processed before it can be used. You should run ./mkclean/configure.compiled from the parent directory instead, after converting its ...
Compile mkclean on ubuntu 16.04
1,431,359,411,000
Where do C# executables running on an Ubuntu Linux 16.04 Lenovo Thinkstation desktop which use source code that DLLImport's shared objects (so's) look for shared objects at runtime? Even if the shared object libxyz.so resides in same subdirectory as the C# executable's subdirectory, I found that it is necessary to ex...
I'll try to answer all three parts of this question for you [Why is it] necessary to export LD_LIBRARY_PATH to ensure correct C# executable program behavior installation programs or scripts manage to find libc.so.6 in the subdirectory /usr/libx86_64-linux-gnu without requiring the customer specify an LD_LIBRARY_PATH ...
Where do C# executables running on an Ubuntu Linux 16.04 desktop which use source code that DLLImport's shared objects look for them at runtime? [closed]
1,450,588,996,000
I've been trying to cross compile the Squid 3.5.7 on ARM Cortex A8 (Linux). I downloaded it from http://www.squid-cache.org/Versions/v3/3.5/ I have arm-linux-gnueabi-gcc and arm-linux-gnueabi-g++. tar -zxvf squid-3.5.7.tar.gz cd squid-3.5.7 ./configure --prefix=/usr/local/squid After ./configure --prefix=/usr/local...
You're not actually cross-compiling; to cross-compile you need to tell ./configure about your target architecture: ./configure --prefix=/usr/local --host=arm-linux-gnueabi You should then get Makefiles which use arm-linux-gnueabi-gcc, and a resulting squid binary which is appropriate for your ARM device. (Assuming yo...
Squid cross compile
1,450,588,996,000
I'm trying to build the libesedb package so I can read edb files. I went to: http://code.google.com/p/libesedb/wiki/Building and found the following: tar xfv libesedb-alpha-<version>.tar.gz cd libesedb-<version> ./configure make So I extracted the files into the folder libesedb-20120102 I then cd to the folder and us...
The ./configure script returns an error regarding your c-compiler. There are some compiler tests that are not working with your gcc. I tried the same on my machine (debian 6) with gcc version 4.4.5 and the ./configure script succeeded without an error. So check your gcc version with gcc --version and install another ...
How to install libesedb? Build error
1,450,588,996,000
I have double-checked that I have every dependency to build X and that they are all at the latest version. I'm not even sure where to begin with these errors, so I was hoping someone here could help me. Compiling on WSL2 if it matters. Compiling using the build.sh method. Here's the command I'm using: ./util/modular/b...
Running the build script as root solved it.
Trying to compile X Window System and getting errors that I don't know
1,450,588,996,000
I am triying to compile on FreeBsd 12.1 .. and game and database source from Metin2 game . I am using gcc+6.5 and gnu gmake -j20 comand Like all the files are getting compiled but in the last second it s getting me this error: linking ../game ld: error: undefined symbol: ERR_free_strings >>> referenced by vio.c >>> ...
Your OpenSSL version is too new for your code. The function was removed in Openssl 1.1.0 According to the changelog: EVP_MD_CTX_cleanup(), EVP_CIPHER_CTX_cleanup() and HMAC_CTX_cleanup() were removed. HMAC_CTX_reset() and EVP_MD_CTX_reset() should be called instead to reinitialise an a...
gmake: *** [Makefile:228: ../game] Error 1
1,450,588,996,000
In trying to compile an old version of libvirt (to see if I can get some old patches up to date, see https://www.redhat.com/archives/libvir-list/2014-March/msg00106.html), I get the error: getopt.h:85:29: fatal error: getopt-pfx-core.h: No such file or directory when I run make (after running ./autogen.sh). This is o...
Make sure that you are building with a clean tree. In this case, I had files from a build of a much newer commit. Running: (warning, this deletes stuff in the working tree that is not in git!) git reset --hard HEAD git clean -fdx git clean -fdX and then doing the build again worked.
Getting the error "getopt.h:85:29: fatal error: getopt-pfx-core.h: No such file or directory" while trying to compile libvirt [closed]
1,450,588,996,000
Monitoring the folder and when the .CPP file arrived inside the folder then automatically compile the program in ubuntu can anyone help me to solve this problem please?
For such a simple case real monitoring (inotify) is probably overkill. #! /bin/bash file_path='/path/to/file.cpp' while true; do if [ -f "$file_path" ]; then : do something exit 0 else sleep 1 fi done
Monitoring folder and compile [closed]
1,450,588,996,000
I don't actually know where to start and what keywords to use for searching more, but can we simply make a programs in C++ that runs in Linux as well as Windows. I guess we are talking about binary files. Does it change the style of programming or do I just have to compile them in different way? If I open a Visual St...
i often use wxwidgets, this places a layer in the code that you work with, which at compile time replaces references to windows / gtk... it does change the way you code as instead of using gtk class or windows.h class direct, you'll use wxwidgets classes which get replaced with appropriate ones at compile time. this g...
C++ Apps ready for Linux as well as Windows? [closed]
1,450,588,996,000
I've successfully been able to configure the latest Firefox (source) without errors. All the required dependencies are in place (i.e. GCC 4.9.2 via devtoolset-3, Python 2.7, Yasm, libffi 3.2.1, and on). When I run ./mach build it also successfully configures and starts makeing the binaries... then after about 24 minut...
That's not a symbol in glibc, it's a symbol in GLib. If you build and install GLib 2.30 or later, you should be able to build Firefox 50.
Compiling Firefox 50 under GLibc 2.12
1,450,588,996,000
The error message I am getting when running ntp-keygen (or ntpd) on my ARM device is: ./ntp-keygen: relocation error: ./ntp-keygen: symbol DSA_generate_parameters_ex, version OPENSSL_1_1_0 not defined in file libcrypto.so.1.1 with link time reference The script to configure, build and install OpenSSL is as follows: #...
Based on the error message you're getting, it looks like the ntp-keygen command is trying to use a function named DSA_generate_parameters_ex from the OpenSSL library, but this function is not defined in the version of the library that you have installed. This could be because you are using an older version of OpenSSL ...
Relocation error when running NTPv4 (cross-compile) on ARM device
1,450,588,996,000
I want to know if there are ways to compile C, C++ and Python code in order to not be able to reverse engineering it over Linux or not? I have heard there are some ways over Windows to do it, but I am working on Linux. I want to compile my code securely, as released or final version. UPDATE At least I want to make ...
preamble you probably don't want to invest time into preventing people from disassembling your code: instead focus on making your project better, so that once your competitors have figured out how you did feature X, your software already has feature Y... the reasoning is simple: if you have a dull project, then nobod...
How to compile c, c++ and python code as "Released/Final" version? [closed]
1,450,588,996,000
So I'm compiling the 6.0.3 kernel in Debian 11, and I've been given the task of getting the smallest kernel possible that boots and has Internet connection. I find myself at a point where I've compiled the kernel 89 times in total, and my kernel has 599 static modules and 0 loadable modules. I'm using the command make...
To build a minimal kernel you should use make tinyconfig instead of make nconfig. To disable the graphic interface, use: sudo systemctl set-default multi-user.target to revert back: sudo systemctl set-default graphical.target But it doesn't make the kernel smaller.
How to disable GUI when compiling the linux kernel?
1,450,588,996,000
I don't understand why us, Linux's users, have to compile source code in order to install apps? Why it can't be like Windows platform, everything is ready to serve as binary packages? Of course, please don't misunderstand that I complain the face compiling-to-run. In fact I love it, it helps me a lot in practicing wi...
As @ivanivan answered, very few distributions require you to compile from source (and Gentoo automates the process.) Traditionally, the main reason why source was preferred was because of the extreme difference in flavour of Unix and architecture that existed between Unix systems (System V vs. BSD, or MIPS vs. Intel a...
Why users have to compile source code to install app on Linux? [closed]
1,450,588,996,000
According to installation guides, having executed on my Debian 12: sudo apt-get install python3 python3-pip python3-setuptools python3-wheel ninja-build sudo apt install build-essential meson should be installed on my system. And if I do a sudo updatedb + locate meson | xargs -I {} dirname {} | sort | uniq I have a...
You need to install it: sudo apt install meson The packages you installed don’t depend on meson, so it wouldn’t have been installed as a dependency. For future reference, you can use apt-file to find packages providing a given command; in this instance: sudo apt install apt-file sudo apt update apt-file search bin/me...
Where is meson? build-essential or python3, python3-pip, python3-setuptools, python3-wheel, ninja-build packages are installed but it isn't here
1,450,588,996,000
I want to find exact source code of compiled program in Linux/Unix systems. for illustration: computer:/ username$ whereis ping /sbin/ping And the task is to find the source code of /sbin/ping.
The source code of a compiled binary may not be available on your system. On OpenBSD (which is not Linux), the source code is for the complete base system (including kernel and utilities like ping) is available over CVS. For a web-browsable OpenBSD repository, see https://cvsweb.openbsd.org/cgi-bin/cvsweb/src/ The pi...
Where are stored sources of compiled programs? [closed]
1,450,588,996,000
I am requesting opinions on expected and desired outcome of prog initialization, specifically loading of shared libraries for a program that I do not have source code. All code delivered via RPMs. Suspect prog exhibits constant Revc-Q buffering on two TCP conns. Other end of TCP conns looks good. Suspect prog buffer...
ldd should always return OK, otherwise the program can't run. On the other hand, there are ways to control where the dynamic linker searches for shared libraries. Based on the reply you got from the program supplier, I assume they have delivered some kind of startup script that sets up the program environment so that ...
Linux Prog has 24 Libs Fails LDD, and strace shows 692 "1 ENOENT" during prog library reads
1,450,588,996,000
I try to compile the newest boost library (1.62.0) on a Linux system with kernel version 2.6.18-92.1.13.el5 (from uname -r), and 2016 intel c++ compiler using gcc 6.1.0. The new intel c++ compiler and gcc are installed at a sub directory of my home directory. I am using an old glibc probably as ancient as the kernel (...
I found the following in the first reference: CentOS 5.2 ships with Boost 1.33.1 If you insist on this hackish approach you need to visit the Boost Archived Versions, and look for version 1.33.1. But notice the release date: Version 1.33.1 December 5th, 2006 12:00 GMT After downloading the version that was sup...
Compile new boost library on linux with ancient kernel
1,450,588,996,000
I'm migrating to from Windows to Linux and I heard a lot about Linux and how you can do some real good programming under Linux. But I'm have no idea about how to compile a code written in C on Linux.
Compile your source file prog.c with: $ gcc prog.c this will generate an executable named a.out. Execute it with: $ ./a.out To specify the name of the executable during compilation: $ gcc prog.c -o prog execute with: $ ./prog gcc is also the C++ compiler. There are plenty command line options available, so i...
How to compile & execute C programs under Linux?
1,450,588,996,000
In terminal, I have compiled a source file named "file.C". I did this by typing g++ file.C -o file. Now, I'd like to know how can I use Unix commands to name the output as "helloworld.out"? Thank you in advance!
Given that $ g++ file.C -o file will create an executable called file, one would hopefully have been able to extrapolate that $ g++ file.C -o helloworld.out will create an executable falled helloworld.out.
How can I name the output of a compiled source file in a certain way?
1,286,899,912,000
I found this question, but I'm sorry I don't quite understand the settings on the two variables ServerAliveInterval and ClientAliveInterval mentioned in the accepted response. If my local server is timing out, should I set this value to zero? Will it then never time out? Should I instead set it to 300 seconds or so...
ServerAliveInterval: number of seconds that the client will wait before sending a null packet to the server (to keep the connection alive). ClientAliveInterval: number of seconds that the server will wait before sending a null packet to the client (to keep the connection alive). Setting a value of 0 (the default) will...
What do options `ServerAliveInterval` and `ClientAliveInterval` in sshd_config do exactly?
1,286,899,912,000
I'm using OpenBox window manager without any desktop environment. xdg-open behaves strangely. It opens everything with firefox. $ xdg-settings --list Known properties: default-web-browser Default web browser I'm looking for a simple program; something like reading every *.desktop file in /usr/share/applic...
You can install and use perl-file-mimeinfo in the extra repository to manage mimetypes. Example to open all .pdf files in apvlv: /usr/bin/vendor_perl/mimeopen -d $file.pdf or on other Linux distributions where mimeopen is NOT in /usr/bin/vendor_perl/ but is in one of the $PATH directories : mimeopen -d $file.pdf and ...
How to properly and easily configure `xdg-open` without any environment?
1,286,899,912,000
I'm using tmux 2.1 and tried to on mouse mode with set -g mouse on And it works fine, I can switch across tmux window splits by clicking the appropriate window. But the downside of this is that I cannot select text with mouse. Here is how it looks like: As you can see, the selection just become red when I keep press...
If you press Shift while doing things with the mouse, that overrides the mouse protocol and lets you select/paste. It's documented in the xterm manual for instance, and most terminal emulators copy that behavior. Notes for OS X: In iTerm, use Option instead of Shift.  In Terminal.app, use Fn.
Tmux mouse-mode on does not allow to select text with mouse
1,286,899,912,000
The header looks like this: #!/bin/sh -e # # rc.local - executed at the end of each multiuser runlevel # # Make sure that the script will "exit 0" on success or any other # value on error. What is the reason for this file (it does not contain much), and what commands do you usually put in it? What is a "multiuser run...
A runlevel is a state of the system, indicating whether it is in the process of booting or rebooting or shutting down, or in single-user mode, or running normally. The traditional init program handles these actions by switching to the corresponding runlevel. Under Linux, the runlevels are by convention: S while booti...
Purpose and typical usage of /etc/rc.local
1,286,899,912,000
Occasionally, I need to check resources on several machines throughout our data centres for consolidation recommendations. I prefer htop primarily because of the interactive feel and the display. Is there a way to customise some settings to my setup for htop? For example, one thing I'd always like to have shown is the...
htop has a setup screen, accessed via F2, that allows you to customize the top part of the display, including adding or removing a "Load average" field and setting it's style (text, bar, etc.). These seem to be auto saved in $HOME/.config/htop/htoprc, which warns: # Beware! This file is rewritten by htop when settin...
How can I set customise settings for htop?
1,286,899,912,000
I thought Moving tmux pane to window was the same question but it doesn't seem to be. Coming from using GNU screen regularly, I'm looking for tmux to do the same things. On of the things I do regularly is have a couple of different windows open, one with some code open in vim, and a couple of terminals windows open t...
tmux and screen have different models so there is no exact equivalent. In screen terms, a split lets you display multiple windows at the same time. next (C-a n) rotates windows through the active part of the split; this lets you rotate “hidden” windows through the active region of the split. In tmux terms, a split div...
How do I cycle through panes inside a window in tmux like in screen?
1,286,899,912,000
The OpenSSH daemon has many "default" values for its settings. So looking at the sshd_config might not give someone the complete set of active settings. How to display the full sshd configuration (for OpenSSH)?
The OpenSSH sshd command has an extended test switch which can be used to "Check the validity of the configuration file, output the effective configuration to stdout and then exit." (source sshd man page). So the answer is (as root, or prefixing it with sudo): sshd -T (the settings are not in alphabetical order, one ...
Display full settings of sshd
1,286,899,912,000
When I run : gvim -p *.xyz I find that not all files are opened in tabs. It feels, like a kind of tab limit? But ! When I try to open unopened with : :tabnew it is opened next to previous tabs - it works ! How to make gvim -p ... to open all files without need of opening those above limit manually with :tabnew ? Bt...
Put this in your .vimrc (usually located at ~/.vimrc): set tabpagemax=100
gvim -p limit of opened tabs?
1,286,899,912,000
I'd like to have a file eg. f with only zsh aliases (pureness reasons). Then I'd like to include f file in my .zshrc file, so that the aliases defined in f are visible in .zshrc. Is it possible? If it is, I could create a script eg. my_alias ($my_alias ll 'ls -l') which appends alias to f file. Of course I could do $e...
.zshrc and .bashrc are script files, not config files, so you "source" the alias file. In Zsh (.zshrc) and Bash (.bashrc) alike: . my_alias will run my_alias and leave its effects in the same environment with the RC files, effectively giving you the aliases in the shell. Of course, your are not limited to aliases eit...
Is it possible to include file in config file of zsh? How?
1,286,899,912,000
There are a number of hidden configuration files in my home directory: some of them are in ~/ (e.g. ~/.cinnamon) some of them are in ~/.config/ (e.g. ~/.config/cinnamon-session) some of them are in ~/.local/share/ (e.g. ~/.local/share/cinnamon-session) What is the logic as to where home configuration files live? a)...
There's a long history here when it comes to the general case of "dot files", but the $HOME/.config and $HOME/.local directories that you specifically mention have an origin in the XDG Base Directory Specification. $HOME/.config is where per-user configuration files go if there is no $XDG_CONFIG_HOME. $HOME/.cache is...
Understanding home configuration file locations: ~/, ~/.config/ and ~/.local/share/
1,286,899,912,000
I usually use grep when developing, and there are some extensions that I always want to exclude (like *.pyc). Is it possible to create a ~/.egreprc or something like that, and add filtering to exclude pyc files from all results? Is this possible, or will I have to create an alias for using grep in this manner, and cal...
No, there's no rc file for grep. GNU grep 2.4 through 2.21 applied options from the environment variable GREP_OPTIONS, but more recent versions no longer honor it. For interactive use, define an alias in your shell initialization file (.bashrc or .zshrc). I use a variant of the following: alias regrep='grep -Er --exc...
Is there a 'rc' configuration file for grep/egrep? (~/.egreprc?)
1,286,899,912,000
On my Ubuntu machine, in /etc/sysctl.conf file, I've got reverse path filtering options commented out by default like this: #net.ipv4.conf.default.rp_filter=1 #net.ipv4.conf.all.rp_filter=1 but in /etc/sysctl.d/10-network-security.conf they are (again, by default) not commented out: net.ipv4.conf.default.rp_filter=1 ...
Checking the value of a sysctl variable is as easy as sysctl <variable name> and, by the way, setting a sysctl variable is as straightforward as sudo sysctl -w <variable name>=<value> but changes made this way will probably hold only till the next reboot. As to which of the config locations, /etc/sysctl.conf or /etc...
Finding out the values of kernel options related to sysctl.conf and sysctl.d
1,286,899,912,000
I've been using the default configuration of vim for a while and want to make a few changes. However, if I edit ~/.vimrc it seems to overwrite all other configuration settings of /etc/vimrc and such, e.g. now there is no syntax highlighting. Here is what vim loads: :scriptnames /etc/vimrc /usr/share/vim/vimfiles/archl...
You can source the global Vim configuration file into your local ~/.vimrc: unlet! skip_defaults_vim source $VIMRUNTIME/defaults.vim set mouse-=a See :help defaults.vim and :help defaults.vim-explained for details.
Extend Default Configuration of vim
1,286,899,912,000
I'm renaming network interfaces by modifying the files in /etc/sysconfig/network-scripts. eth0 -> nic0 eth1 -> nic1 The content of the network scripts looks like this, after modification: # cat /etc/sysconfig/network-scripts/ifcfg-nic0 DEVICE=nic0 BOOTPROTO=static ONBOOT=yes HWADDR=xx:xx:xx:xx:xx:xx USERCTL=no IPV6I...
You can rename the device using the ip command: /sbin/ip link set eth1 down /sbin/ip link set eth1 name eth123 /sbin/ip link set eth123 up Edit: I am leaving the below for the sake of completeness and posterity (and for informational purposes,) but I have confirmed swill's comment and Marco Macuzzo's answer that sim...
CentOS 7 - Rename network interface without rebooting
1,286,899,912,000
I want to add a permanent iptables rule to my new VPS, and after brief google search i was surprised that there are two places this rule can be added, that seems like identical: /etc/rc.local and /etc/init.d/rc.local. Maybe someone knows why where is two places for simple startup code to place? Is it linux flavor spec...
/etc/init.d is maintained on ubuntu for backward compatibility with sysvinit stuff. If you actually look at /etc/init.d/rc.local you'll see (also from a 12.04 LTS Server): #! /bin/sh ### BEGIN INIT INFORMATION # Provides: rc.local # Required-Start: $remote_fs $syslog $all # Required-Stop: # Default-Start:...
What's the difference between /etc/rc.local and /etc/init.d/rc.local?
1,286,899,912,000
I've found tons of sites that explain how to have git warn you when you're changing line endings, or miscellaneous other techniques to prevent you from messing up an entire file. Assume it's too late for that -- the tree already has commits that toggle the line endings of files, so git diff shows the subtraction of th...
For diff, there's git diff --ignore-space-at-eol, which should be good enough. For diff and blame, you can ignore all whitespace changes with -w: git diff -w, git blame -w. For git apply and git rebase, the documentation mentions --ignore-whitespace. For merge, it looks like you need to use an external merge tool. You...
Ignore whitespaces changes in all git commands
1,286,899,912,000
Ok, so I've been searching the web for solutions to this problem with no answers seeming to work for me. Hopefully someone can help me. I'm only trying to configure the OpenVPN Client. I'm running CrunchBang Linux 3.2.0-4-amd64 Debian 3.2.60-1+deb7u1 x86_64 GNU/Linux and I just switched over to using systemd. The ...
I think the Debian OpenVPN setup with systemd is currently a tad bit broken. To get it to work on my machines I had to: Create /etc/systemd/system/[email protected] (the directory), and place in it a new file with this:[Unit] Requires=networking.service After=networking.serviceI called my file local-after-ifup.conf. ...
Using OpenVPN with systemd
1,286,899,912,000
Is there any way to automate Linux server configuration? I'm working on setting up a couple of new build servers, as well as an FTP server, and would like to automate as much of the process as possible. The reason for this is that the setup and configuration of these servers needs to be done in an easily repeatable w...
Yes! This is a big deal, and incredibly common. And there are two basic approaches. One way is simply with scripted installs, as for example used in Fedora, RHEL, or CentOS's kickstart. Check this out in the Fedora install guide: Kickstart Installations. For your simple case, this may be sufficient. (Take this as an e...
How to automate Linux server configuration?
1,286,899,912,000
Is there a way to dynamically assign environment variables in a systemd service unit file? We have a machine that has 4 GPUs, and we want to spin up multiple instances of a certain service per GPU. E.g.: gpu_service@1:1.service gpu_service@2:1.service gpu_service@3:1.service gpu_service@4:1.service gpu_service@1:2.se...
If you are careful you can incorporate a small bash script sequence as your exec command in the instance service file. Eg ExecStart=/bin/bash -c 'v=%i; USE_GPU=$${v%:*} exec /bin/mycommand' The $$ in the string will become a single $ in the result passed to bash, but more importantly will stop ${...} from being inter...
Dynamic variables in systemd service unit files
1,286,899,912,000
A lot of unix config files in xx.d folders are prefixed by a number, like : $ ls /etc/grub.d/ 00_header 10_linux 30_os-prober 40_custom 05_debian_theme 20_linux_xen 30_uefi-firmware 41_custom Is there any convention on this number? What does it mean ? Might just be to avoid name clashing but I'm...
It's a convention used both to keep filenames unique, and to control the order in which scripts get executed. In general, the xx.d directories are scanned by something doing the moral equivalent of for file in /etc/grub.d/*; do ... and the numeric prefixes give this an ordering other than alphabetical. There may be ...
What is the number prefix in config files from .d directory
1,286,899,912,000
On Ubuntu 10.4 I have edited the /etc/bash.bashrc file to set some variables like the command history size (HISTSIZE=5000), however if I create a new users Ubuntu by default gives them a .bashrc file in their home directory with this set as HISTSIZE=1000 which is overriding mine. How can I change the default .bashrc f...
You may put default configurations in /etc/skel so that useradd(8) can copy files in /etc/skel whenever it creates new user's directory by '-m' option. Note that this is used only for the new-user. Existing user accounts are not affected.
How do I set a user's default .bashrc file?
1,286,899,912,000
there are so many tutorials out there explaining how to setup dhcpd server, in relation to providing ntp suggestions to dhcp clients, that I had always thought that ntp configuration was carried out automatically. Recently I started seeing clock drifts in my local network, so I assume this was a wrong assumption. So I...
If the dhcp server you are using is configured to provide the ntp-servers option, you can configure your dhclient to request ntp-servers by adding ntp-servers to the default request line in dhclient.conf, as shown at the end of this example from Ubuntu Linux (as of 19.04, but present since at least 12.04): request sub...
how do you set up a linux client to use ntp information provided through dhcp?
1,286,899,912,000
How can I establish a reverse ssh tunnel with my ./ssh/config file? I'm trying to reproduce this command ssh -R 55555:localhost:22 user@host in my .ssh/config file so that when I type ssh host I'll ssh to the host as user and with a reverse tunnel. The commands accepted by the config file are more verbose counterpart...
BindAddress is not the option you're after. From man ssh_config: BindAddress Use the specified address on the local machine as the source address of the connection. Only useful on systems with more than one address. The configuration file equivalent of -R is RemoteForward: RemoteForward ...
Reverse ssh tunnel in config
1,286,899,912,000
I am thinking on a system, where /etc were tracked on a remote git repository. I am thinking on a git workflow, where every host machine where a different branch. Every previous versions on every machine could be easily tracked, compared, merged. If a /etc modification had to be committed on many machines, it could be...
The program etckeeper does manage /etc in git, you just need to change the default vcs backend from bzr to git in /etc/etckeeper/etckeeper.conf. It is installed by default in Ubuntu Linux, and handles the common cases of when to commit automatically. It commits before installing packages in case there are uncomitted m...
Using git to manage /etc?
1,286,899,912,000
I'm trying to apply the same sshd settings to multiple users. According to the manual, it seems Match User acts like an AND: Introduces a conditional block. If all of the criteria on the Match line are satisfied, the keywords on the following lines override those set in the global section of the config file How do I...
Not having done this myself, I can only go on what the manuals say: From the sshd_config manual: The match patterns may consist of single entries or comma-separated lists and may use the wildcard and negation operators described in the PATTERNS section of ssh_config(5). This means that you ought to be able to say Ma...
Match multiple users in 'sshd_config'
1,286,899,912,000
I want to set up a plugin for the Geany editor on a Debian system. It's a theme changing plugin, so I am following this manual. It says: The simplest way to do this is to copy the contents of the archive into the ~/.config/geany/filedefs/ folder. I don't understand this. What do they mean by ~/.config? Is that the...
~ is your home directory, usually /home/username. A file or folder name starting with a . is the Linux version of a hidden file/folder. So ~/.config is a hidden folder within your home directory. Open up your file browser to your home folder, then find the option to show hidden files and folders. If you don't see .c...
What ~/.config refers to and how to put files there?
1,286,899,912,000
So SSH has these files that configure settings for a specific user. ~/.ssh/authorized_keys ~/.ssh/config ~/.ssh/id_rsa ~/.ssh/id_rsa.pub ~/.ssh/known_hosts I'd like to globalise some of these files, like config and known_hosts. So that other users ( including root ) could share the configured hosts. What would be the...
For ~/.ssh/config you can place relevant system-wide settings in /etc/ssh/ssh_config according to the man page: ssh(1) obtains configuration data from the following sources in the following order: command-line options user's configuration file (~/.ssh/config) system-wide configuration file (/etc/ssh/ssh_con...
making ssh hosts global to all the users on the computer
1,286,899,912,000
I was wondering if there's a way to find out the default shell of the current user within a shell script? Use case: I am working on a script that sets an alias for a command and this alias is set within a shell script. !# /bin/bash alias = 'some command to set the alias' There's a logic in the script where it tries t...
$ finger $USER|grep -oP 'Shell: \K.*' /bin/mksh
Finding out the default shell of a user within a shell script
1,286,899,912,000
I'm mounting a NFS filesystem on my machine. How do I figure out what version of the NFS protocol the server uses? I don't have access to the NFS server machine, but I do have root on my client machine. Is there anything I can run on my client machine to identify what version of the NFS protocol is being used by the...
The nfsstat -c program will show you the NFS version actually being used. If you run rpcinfo -p {server} you will see all the versions of all the RPC programs that the server supports. On my system I get this output: $ rpcinfo -p localhost program vers proto port 100000 2 tcp 111 portmapper 10000...
Which version of NFS is my NFS server using?
1,286,899,912,000
When zsh shows you a menu of possible completions, I'd like it to let me use shift-tab to access previous completion entries--is there an option that controls what key is used to access previous completion entries? And if so, what would I need to add to my ~/.zshrc file in order to set it up. If it makes any diff...
you want to bind the editor command reverse-menu-complete to the menuselect keymap. bindkey -M menuselect '^[[Z' reverse-menu-complete I am not sure how portable the escape sequence ^[[Z is, so you may want to check terminfo(5) to see if there is a way of using the $terminfo array to correctly bind it. Note that the ...
Zsh completion, enabling shift-tab
1,286,899,912,000
Due to work I have recently started using OS X and have set it up using homebrew in order to get a similar experience as with Linux. However, there are quite a few differences in their settings. Some only need to be in place on one system. As my dotfiles live in a git repository, I was wondering what kind of switch I ...
Keep the dotfiles as portable as possible and avoid OS dependent settings or switches that require a particular version of a tool, e.g. avoid GNU syntax if you don't use GNU software on all systems. You'll probably run into situations where it's desirable to use system specific settings. In that case use a switch stat...
How to keep dotfiles system-agnostic?
1,286,899,912,000
I want to make "echo 1 > /sys/kernel/mm/ksm/run" persistent between boots. I know that I can edit /etc/sysctl.conf to make /proc filesystem changes persist, but this doesn't seem to work for /sys. How would I make this change survive reboots?
Most distros have some sort of an rc.local script that you could use. Check your distro as names and path may vary. Normally expect to look under /etc.
Make changes to /sys persistent between boots
1,286,899,912,000
I usually turn the alert sound (by default a water drop sound) off by going to control-center→Sound→Sound Effects and muting the Alert volume. This is in Gnome. I wanted to turn it off in a custom live build of Debian by default, but I can't figure where this setting is stored. I tried dconf and looked around config d...
This can be achieved by this command dconf write /org/gnome/desktop/sound/event-sounds "false" However, this doesn't turn off the sound volume slider effect. To completely turn off the sound effects the closest way I've found was to live boot into a clean iso of the distro and open the System settings > Sound > Soun...
How to turn off alert sounds/sound effects on Gnome from terminal?
1,286,899,912,000
Specifically AllowUsers parameter: e.g. convert this AllowUsers user1 user2 user3 user4 to this AllowUsers user1 user2 user3 user4
No, but it's not useful in this case. You can have multiple AcceptEnv, AllowGroups, AllowUsers, DenyGroups, DenyUsers, HostKey, PermitOpen, Port and Subsystem lines, and each line adds one or more (or sometimes zero) elements to the list. Nonetheless, if you can't easily fit your AllowUsers directive on one line, I su...
Is it possible to break long lines in sshd_config?
1,286,899,912,000
A few months ago, meld started behaving oddly. Common lines are almost unreadable, and shown as dark grey text on a black background. Oddly enough, running it as root is fine (with kdesudo meld), although the theme is less pretty. How can I specify the text's colour options for meld? I'm using: Arch Linux KDE 4.14....
It looks like it was a regression introduced in Meld 3.12.1. I downloaded previous versions from the meld website. Meld 3.12.0 works fine. Meld 3.12.1 does not. I contacted the devs and they told me that it was indeed a regression introduced in the gtk+ 3 port. They suggested trying the just-released 3.12.3, which n...
How can I make text in meld readable?
1,286,899,912,000
When I boot, PulseAudio defaults to sending output to Headphones. I'd like it to default to sending output to Line Out. How do I do that? I can manually change where the output is current sent as follows: launch the Pulseaudio Volume Control application, go to the Output Devices tab, and next to Port, select the Lin...
I had the same problem (for at least a year now), and the following seemed to work: Taken from: https://bbs.archlinux.org/viewtopic.php?id=164868 Use pavucontrol to change the port to your desired one. Then find the internal name of the port with this command: $ pacmd list | grep "active port" active port: <hdmi-o...
Change default port for PulseAudio (line out, not headphones)
1,286,899,912,000
I get that I can use mount to set up / directories and that I can use the /etc/fstab to remount them on reboot. Testing the fstab file is also fun with mount -faV. When I'm looking at the fstab file, the number of space is disconcerting. I would have expected one space (like a separator between command parameters) o...
The number of spaces is a way to cosmetically separate the columns/fields. It has no meaning other than that. I.e. no the amount of white space between columns does not matter. The space between columns is comprised of white space (including tabs), and the columns themselves, e.g. comma-separated options, mustn't cont...
What are all the spaces in the /etc/fstab for?
1,286,899,912,000
When I turned on my Ubuntu 18.04 yesterday and wanted to start GitKraken, it did not work. After I click its icon I see how the process tries to start in the upper left corner (next to "Activities") but after a few seconds the process seems to die and nothing happens. Trying to launch GitKraken from the console fails ...
SOLVED: Had to install libgnome-keyring: sudo apt install libgnome-keyring0 The UI now comes up and works for me. Still get the following warnings, but it's working: Gtk-Message: 11:19:31.343: Failed to load module "overlay-scrollbar" Gtk-Message: 11:19:31.349: Failed to load module "canberra-gtk-module" Node started ...
GitKraken does not start anymore on Ubuntu 18.04
1,286,899,912,000
When I view a message in the pager mutt displays the time in the Date header in UTC rather than my local time zone. The index view displays the local time correctly. I found this old mailing list post that describes how to get the local time to display in the status bar at the bottom of the screen, but this still does...
In your .muttrc add the following line: set display_filter="exec sed -r \"s/^Date:\\s*(([F-Wa-u]{3},\\s*)?[[:digit:]]{1,2}\\s+[A-Sa-y]{3}\\s+[[:digit:]]{4}\\s+[[:digit:]]{1,2}:[[:digit:]]{1,2}(:[[:digit:]]{1,2})?\\s+[+-][[:digit:]]{4})/date +'Date: %a, %d %b %Y %H:%M:%S %z' -d '\\1'/e\"" This will change the Date: he...
How do I configure mutt to display the date header in my local time zone in the pager?
1,286,899,912,000
I currently run Angstrom Linux 2.6.32. I intend to upgrade linux kernel from 2.6.32 to 3.0.7. For this reason, I had to configure kernel 3.0.7 running make menuconfig. Now, I want to compare the new kernel configuration with the previous, but I can't find kernel 3.0.7 configuration file. Any ideas?
Your new one is .config at the top level of your kernel source tree. It may also get installed to /boot/config-3.0.7 or similar, depending.
Where kernel configuration file is stored?
1,286,899,912,000
I'm running a small server for our flat share. It's mostly a file server with some additional services. The clients are Linux machines (mostly Ubuntu, but some others Distros too) and some Mac(-Book)s in between (but they're not important for the question). The server is running Ubuntu 11.10 (Oneiric Ocelot) 'Server E...
Using any mount system, you want to avoid situations where Nautilus lists the directory containing a mount that may or not be mounted. So, with autofs, don't create mounts in, for instance, /nfs. If you do, when you use Nautilus to list the 'File System' it will try to create whatever mounts should exist in /nfs, an...
automount nfs: autofs timeout settings for unreliable servers - how to avoid hangup?
1,283,688,724,000
I have a few different linux machines and a lot of config files (and folders) on each. For example: ~/.ssh/config ~/.config/openbox/rc.xml ~/.config/openbox/autostart.sh ~/.scripts/ ( folder ) ~/.bashrc ...etc Is there a simple and elegant method to keep these files synced between my machines ( one has no internet ac...
Keep the files under version control. This has multiple benefits, including facilitating keeping files synchronized (commit on one machine, update on the others) and keeping a history of changes (so you can easily find out what broke a program that worked last month). I use CVS and synchronize the repositories with Un...
Keeping config files synced across multiple pc's
1,283,688,724,000
What are the differences in dependencies between select and depends on in the kernels Kconfig files? config FB_CIRRUS tristate "Cirrus Logic support" depends on FB && (ZORRO || PCI) select FB_CFB_FILLRECT select FB_CFB_COPYAREA select FB_CFB_IMAGEBLIT ---help--- This enables support for Cirrus Logic GD542x/543x based ...
depends on A indicates the symbol(s) A must already be positively selected (=y) in order for this option to be configured. For example, depends on FB && (ZORRO || PCI) means FB must have been selected, and (&&) either ZORRO or (||) PCI. For things like make menuconfig, this determines whether or not an option will be...
What is the difference between "select" vs "depends" in the Linux kernel Kconfig?
1,283,688,724,000
I'm trying to set up automatic SSH hopping through a server which doesn't have nc. This works from the command line: ssh -A gateway ssh steve@target (I have added my public key to the SSH agent). However, adding it to ~/.ssh/config doesn't: Host target User steveb ProxyCommand ssh -A gateway ssh steve@targetip $...
SSH ProxyCommand without netcat The ProxyCommand is very useful when hosts are only indirectly accessible. With netcat it is relative strait forward: ProxyCommand ssh {gw} netcat -w 1 {host} 22 Here {gw }and {host} are placeholders for the gateway and the host. But it is also possible when netcat is not installed on...
Pseudo-terminal will not be allocated because stdin is not a terminal
1,283,688,724,000
Subtitle files come in a variety of formats, from .srt to .sub to .ass and so on and so forth. Is there a way to tell mpv to search for subtitle files alongwith the media files and if it does to start playing the file automatically. Currently I have to do something like this which can be pretty long depending on the f...
As seen in man mpv: --sub-auto=<no|exact|fuzzy|all>, --no-sub-auto Load additional subtitle files matching the video filename. The parameter specifies how external subtitle files are matched. exact is enabled by default. no Don't automatically load external subtitle file...
Play subtitles automatically with mpv
1,283,688,724,000
So, I have a bunch of machines I manage, where I've aliased each of them for ease of access. This looks like this for each of them in the ssh client config: Host MACHINE-1075 M1075 m1075 1075 User service HostName 10.0.100.75 And also: Match User service IdentityFile ~/.ssh/service_user Which allows me t...
It's IMHO not entirely clear in man ssh_config, however the syntax for matching multiple conditions appears to be Match keyword [pattern|pattern-list] keyword [pattern|pattern-list] where patterns in pattern-list are comma-separated, but keyword pattern pairs are separated from one another by simple whitespace: Match...
Matching both user and host simultaneously in SSH config
1,283,688,724,000
I have been using w3m for a couple of weeks and am convinced that it is my preferred text browser - with one exception. Is there any way to yank URLs to the clipboard without using the mouse? I have looked through the manual and, using the default keybindings, there doesn't appear to be any documented way to do this. ...
Set the “External Browser” option to sh -c 'printf %s "$0" | xsel' You can use xsel -b to use the clipboard instead of the primary selection. An alternative to xsel is xclip (xclip for the primary selection, xclip -selection CLIPBOARD for the clipboard). In ~/.w3m/config, that's the extbrowser setting. Then press M t...
Yanking URLs in w3m
1,283,688,724,000
I was using the mouse copy-paste extensively, until recently, when some OpenSuSe upgrade reconfigured this on all my machines. Now the scrollbuton is the one to paste (which I hate, since it's hard to click without scrolling, and I also click it sometimes accidentally). Where is this configured? Ideally I would love s...
It is configured in /etc/X11/xorg.conf. You'll see a section that looks like Section "InputDevice" Identifier "Configured Mouse" Driver "mouse" Option "CorePointer" Option "Device" "/dev/input/mice" Option "Protocol" ...
Configuring mouse for right+left button simulating middle click (for copy/paste)
1,283,688,724,000
I woud like to set up the default sound volume once for all, for all ALSA devices that will be connected ever. Of course, I could do amixer ... or even alsamixer to modify the volume of currently available soundcards. But I really want to modify the default volume even for future soundcards that will be added later. I...
There are some generic and driver-specific config files in /usr/share/alsa/init/, where you can specify settings like ENV{ppercent}:="75%" and ENV{pvolume}:="-20dB" (pvolume = playback volume, cvolume = capture volume, etc.). /usr/share/alsa/init/default should already contain those settings, so you can use it as an e...
Default sound volume for all ALSA devices
1,283,688,724,000
I don't have a desktop manager installed (and I don't want to). After logging in through the terminal I use startx to start the GUI. I have entries in ~/.xinitrc for my GUI sessions. Right now I have xmonad in there, but sometimes I want to run a GNOME session, and sometimes a KDE session. I used to edit ~/.xinitrc fo...
According to the xinit man page that I read, xinit (and thereby startx) looks in its command line parameters for a client program to run. If it doesn't find one, it runs ~/.xinitrc instead. So you should be able to write startx path/to/my_alternate_xinitrc and it will do what you want. You will need to provide a p...
How to make startx use alternate xinitrc?
1,283,688,724,000
I run Gnome, which has pretty good support for my HiDPI screen. However, when I run QT apps I can't seem to find a way to scale the fonts. Is there a way to do this without installing a full version of KDE?
Updated: Since Qt 5.6, Qt 5 applications can be instructed to honor screen DPI by setting the QT_AUTO_SCREEN_SCALE_FACTOR environment variable. If automatic detection of DPI does not produce the desired effect, scaling can be set manually per-screen (QT_SCREEN_SCALE_FACTORS) or globally (QT_SCALE_FACTOR). You can also...
How can I set the default font size for all Qt5 apps?
1,283,688,724,000
I have a system without X display and I want to use nmcli to configure my cell modem to connect to a certain apn. I can get it going with this modem just fine on Ubuntu (with X) and I would like to achieve the same now on the command line. How can I setup the connection? so far I get this: # nmcli dev status ** (proc...
A bit late to the party, but I was stuck at the same hurdle. Since I have worked it out I thought I'd share my findings as every other post on the topic is about as clear as mud. Although NetworkManager can see the device, it doesn't know of any connections that are supported by the device. Unlike WiFi, we can't just ...
configure gsm connection using nmcli
1,283,688,724,000
I'd like a tcsh'ism that I haven't been able to find: On a blank line with no content, I want to press the tab key and see the equivalent of an ls. That is to say I want $ <tab> to do something other then giving me a \t. I've found fantastic resources for command completion, but not for this base case. Any help o...
# expand-or-complete-or-list-files function expand-or-complete-or-list-files() { if [[ $#BUFFER == 0 ]]; then BUFFER="ls " CURSOR=3 zle list-choices zle backward-kill-word else zle expand-or-complete fi } zle -N expand-or-complete-or-list-files # bind to tab bindkey ...
zsh tab completion on empty line
1,283,688,724,000
I want to create a script that runs when a Zsh instance starts, but only if the instance is: Non-login. Interactive I think I'm right to say .zshrc runs for all interactive shell instances, .zprofile and .zlogin run for all login shells, and .zshenv runs in all cases. The reason I want to do this is to check if ther...
if [[ -o login ]]; then echo "I'm a login shell" fi if [[ -o interactive ]]; then echo "I'm interactive" fi [[ -o the-option ]] returns true if the-option is set. You can also get the values of options with the $options special associative array, or by running set -o. To check if there's an ssh-agent: if [[ -w $...
How would I detect a non-login shell? (In Zsh)
1,283,688,724,000
A lot of Linux programs state that the config file(s) location is distribution dependent. I was wondering how the different distributions do this. Do they actually modify the source code? Is there build parameters that sets these locations? I have searched for this but cannot find any information. I know it's out ther...
It depends on the distribution and the original ('upstream') source. With most autoconf- and automake-using packages, it is possible to specify the directory where the configuration files will be looked for using the --sysconfdir parameter. Other build systems (e.g., CMake) have similar options. If the source package ...
How do different distributions modify the locations of config files for programs?
1,283,688,724,000
How can I exclude files by default with rsync? Here is how my normal rsync syntax starts out: rsync --exclude ".ht*" --exclude "error_log" --exclude ".DS*" --exclude "old" ... I've seen a lot of mention of configuring the /etc/rsyncd.conf file, but maybe that's more for the daemon than the rsync command. Is it possib...
Add your excludes to a file, then use --exclude-from=/path/to/exclude_file e.g. # cat rsync.excludes .ht* error_log .DS* old ... # rsync --exclude-from=rsync.excludes
How can I exclude files by default with rsync?
1,283,688,724,000
I want to disable VSync (it's called "Sync to VBlank" in nvidia-settings) for my nvidia graphics card. But the configuration only takes effect if I start the nvidia-settings tool. After rebooting the system VSync is enabled again and I have to start the program again. I tried exporting the xorg.conf and putting it in...
Looking into the readme indeed helps sometimes :) This behaviour is intentional to give different users the chance to have their own settings. In short the nvidia-settings config file is stored in ~/.nvidia-settings-rc and can be executed by calling nvidia-settings --load-config-only at startup. For more details, here...
How to make changes in nvidia-settings tool persistent
1,283,688,724,000
Mozilla just released a new tool to check your website configuration. observatory.mozilla.org But the scan is complaining about Cookies (-10 points): Session cookie set without the Secure flag ... Unfortunately the service running behind my nginx can only set the secure header if the SSL terminates there directly and...
I know two ways to sorta do this, neither of them great. The first is to just abuse proxy_cookie_path like this: proxy_cookie_path / "/; secure"; The second is to use the more_set_headers directive from the Headers More module like this: more_set_headers 'Set-Cookie: $sent_http_set_cookie; secure'; Both of these c...
Nginx Add Secure Flag to Cookies from proxied server
1,283,688,724,000
I believe that if there is any output from a cronjob it is mailed to the user who the job belongs to. I think you can also add something like [email protected] at the top of the cron file to change where the output is sent to. Can I set an option so that cron jobs system-wide will be emailed to root instead of to the ...
Check /etc/crontab file and set MAILTO=root in there. Might also need in /etc/rc file crond seems to accept MAILTO variable, I guess I am not sure completely but its worth a try changing the environment variable for crond before it is started. Like in /etc/sysconfig/crond or /etc/rc.d/init.d/crond script which source...
Can I change the default mail recipient on cron jobs?
1,283,688,724,000
I've just moved to Awesome WM from OpenBox. I like that it's very extensible, customizable and I have huge control about window layout. I like structured and organized things and I'd like to separate that huge .config/awesome/rc.lua configuration into multiple files.
You can simply place code in a separate file and include it with dofile("somefile.lua") Note: The working directory is $HOME. To specify a file relative to rc.lua you can use dofile(awful.util.getdir("config") .. "/" .. "somefile.lua") If it's more than just some code and it might be used by others as well, it might...
How to separate Awesome's `rc.lua` configuration into multiple files?
1,283,688,724,000
How to change the applications associated with certain file-types for gnome-open, exo-open, xdg-open, gvfs-open and kde-open? Is there a way by editing config files or by a command-line command? Is there a way to do this using a GUI? For both questions: How to do it per user basis, how to do it system-wide?
It's all done with MIME types in various databases. xdg-mime can be used to query and set user values.
Change default applications used by gnome-open, exo-open, xdg-open, gvfs-open and kde-open
1,283,688,724,000
I want to tweak smb.conf without causing network hiccups for folks who rely on our samba4 fileshare. I made an obvious path change that should only affect my own private share, and ran smbcontrol smbd reload-config. It didn't complain, but didn't affect my share, either. I also tried smbcontrol samba4 reload-config,...
You can try with sending SIGHUP signal to smbd process killall -HUP smbd nmbd NOTE: Be careful using killall on Unix. Running killall on Solaris on root would send kill signals to all processes! [en.wikipedia.org/wiki/Killall]
Reloading Samba4's smb.conf without restarting the service
1,283,688,724,000
What is the file format expected by iptables-restore? Does a description of the format exist?
I found my answer, sort-of... As best as I can tell, there is no document. However, in reading the source code I've uncovered how it works. Lines starting with # are for comments and are not parsed. Blank lines are ignored. * marks the table name. : marks the chain, followed by the default policy and optionally the pa...
netfilter - iptables-restore file format documentation
1,283,688,724,000
I configured the service - calc_mem.service as the following Restart=on-failure RestartSec=5 StartLimitInterval=400 StartLimitBurst=3 the configuration above should do the following from my understanding the service have 3 retries when service exit with error and before service start it will wait 5 seconds also I ...
The systemd.service man page has a description of the values Restart= takes, and a table of what options cause a restart when. Always pretty much does what it says on the lid: If set to always, the service will be restarted regardless of whether it exited cleanly or not, got terminated abnormally by a signal, or hit ...
systemctl + what is the meaning of Restart=always
1,283,688,724,000
I use BIND as my DNS server at home. For my Start Of Authority (SOA record) I always use a serial in the recommended format YYYYMMDD## where ## is the counter for changes on that day. Unfortunately I changed the serial and added 1 more digit by mistake. After updating the name-daemon, I couldn't revert this anymore...
"BIND's internal libraries" don't care what the serial number is. It's only agreement between the master server and slave servers that matters. In other words, BIND will happily let you decrease the serial number in a zone file without complaint.. It's just that the slaves would no longer receive updates. Zone file se...
How can I reset or lower the serial used in BIND DNS server's SOA record?
1,283,688,724,000
Specifically I'm trying to give a notification after some command was completed. So, for example, if I reload my configuration file, I'd like to have some confirmation that it worked, which might be done something like this: bind R source-file "$HOME/.tmux.conf" && display-message "Configuration reloaded." That, how...
You could use the run-shell option, but the critical thing is to separate the commands with \; In this case, something like: bind R source-file ~/.tmux.conf \; run-shell "echo 'Reload'" run-shell shell-command (alias: run) Execute shell-command in the background without creating a window. After it finishes, an...
How can I bind multiple tmux commands to one keystroke?
1,283,688,724,000
I would like to set an environment variable so that it is set when I launch a specific Flatpak application, and only set for this application. How do I go about doing this in a permanent manner?
You can do this via the flatpak override command. To set only one environment variable you can use this syntax: flatpak override --env=VARIABLE_NAME=VARIABLE_VALUE full.application.Name To set multiple environment variables you can use this syntax: flatpak override --env=VARIABLE_NAME_ONE=VARIABLE_VALUE_ONE --env=VAR...
How do I permanently set an environment variable for a specific Flatpak application?
1,283,688,724,000
OS: Funtoo. I have bound NGINX to port 81 (I want to run it alongside my Apache server for a short time for ease of transition), and it listens at the port (If I point at another port, using wget I get "Connection refused", but using port 81 I get "connected") but it never serves an HTML response of any kind! When run...
Turns out the big problem? Nginx had set worker_processes to 0. I added a line setting it to auto in the top of my nginx.conf, and all was well with the world! Thank you all for your time and patience.
Nginx listens at a port, only responds if set to port 80
1,283,688,724,000
I frequently ssh into openstack instances. All of the instances are on a dedicated vlan and subnet (10.2.x.x). All of the instances have the same username (bob) I connect like so: ssh [email protected] or sometimes like this ssh 10.2.x.x -l bob Is it possible to configure my laptop to automatically use the name bob ...
The ssh_config man page has a section PATTERNS which details how you can do that, you can use wildcards of * and ?. In my ~/.ssh/config: Host 172.16.*.* User drav and then on issuing ssh -vvv 172.16.13.1: debug1: Reading configuration data /home/drav/.ssh/config debug1: /home/drav/.ssh/config line 4: Applying opti...
ssh config wildcards to avoid typing username
1,283,688,724,000
From the output of lspci how do I interpret the BUSID for xorg.conf.d ? Example: 00:02.0 VGA compatible controller: Intel Corporation Skylake GT2 [HD Graphics 520] (rev 07) 01:00.0 Display controller: Advanced Micro Devices, Inc. [AMD/ATI] Sun XT [Radeon HD 8670A/8670M/8690M / R5 M330 / M430 / Radeon 520 Mobile] (rev...
In your lspci output, 01:00.0 means bus 1, device 0, function 0, which maps to a BusID specifier of PCI:1:0:0 (without specifying the domain): BusID "PCI:1:0:0" See the xorg.conf documentation for details.
Setting BUSID in xorg.conf
1,283,688,724,000
Recently Gnome came up with a new feature of Night Light. It is really helpful. It feels too time-consuming that I need to go to settings (and then display) and activate it each time. Is there any terminal command that can simply turn on the night light feature? Manual and/or sunrise to sunset option aren't really hel...
Yes, you can turn it on with gsettings set org.gnome.settings-daemon.plugins.color night-light-enabled true or dconf write /org/gnome/settings-daemon/plugins/color/night-light-enabled true Same commands with false instead of true will turn it off. If you list the keys under the org.gnome.settings-daemon.plugins.co...
Activate Night Light option from terminal
1,283,688,724,000
The main apache config file is in /etc/httpd/conf/httpd.conf on my CentOS system an in there is a line: Include conf.d/*.conf Inside conf.d is mostly files that do something like this: LoadModule auth_kerb_module modules/mod_auth_kerb.so But there are also other sites that are setup in there to and have their own co...
Separating configuration files is a way to manage them. By putting configuration lines specific to a module into their own files it become much easier to enable and disable modules. It also helps managing them, because now you only have a small configuration file to edit. (Imagine opening up a 500 line httpd.conf and ...
Why put some config info in conf/httpd.conf and some in files in the conf.d folder?
1,283,688,724,000
I saw a kernel option today in menuconfig that used braces for its checkbox. {*} Button This isn't listed in the legend at the top of the screen. [*] built-in [ ] excluded <M> module < > module capable What do the braces signify?
It represents an option that has been implied to a specific value by another option. This Gentoo's wiki has a clear explanation and lists all the available types that menuconfig can display. For example: the hyphen is also listed there.
What do the kernel options in braces mean?
1,283,688,724,000
I want to enable reversed path filtering to prevent source ip spoofing on my server. I noticed that I have the following settings at current: net.ipv4.conf.all.rp_filter = 0 net.ipv4.conf.default.rp_filter = 1 net.ipv4.conf.lo.rp_filter = 0 net.ipv4.conf.p4p1.rp_filter = 1 net.ipv4.conf.eth0.rp_filter = 1 The settin...
According to this post titled: all vs. default in /proc/sys/net/ipv4/conf [message #3139]: When you change variables in the /proc/sys/net/ipv4/conf/all directory, the variable for all interfaces and default will be changed as well. When you change variables in /proc/sys/net/ipv4/conf/default, all future interfaces wi...
What is the difference between all and default in kernel setting? [duplicate]
1,283,688,724,000
I have Rapsberry Pi B+ with Arch Linux installation. uname reports version: [computer@computer001 ~]$ uname -a Linux computer001 3.18.3-3-ARCH #1 PREEMPT Mon Jan 26 20:10:28 MST 2015 armv6l GNU/Linux I've installed ftp server via pacman -S vsftpd and installation has passed without any errors. Then I tried to configu...
I've reset the permissions for /etc/vsftpd.conf to root:root via sudo chown root:root /etc/vsftpd.conf and now the vsftpd server get started via sudo systemctl restart vsftpd.service and running it manually via sudo /usr/bin/vsftpd.
vsftpd won't start: "systemd[1]: vsftpd.service: main process exited, code=exited, status=2/INVALIDARGUMENT"
1,283,688,724,000
I want to disable the bold font in my urxvt config (.Xresources). xterm has the option allowBoldFonts. Is there a similar option for urxvt? I can't find anything similar.
You can effectively disable bold fonts by just applying the same font string for both urxvt's regular and bold fonts in .Xresources, for example: URxvt.font:xft:droid sans mono slashed:size=10.5 URxvt.boldFont:xft:droid sans mono slashed:size=10.5
Disable bold font in urxvt
1,283,688,724,000
If I look at my home directory there are a large number of dot files. If I am creating a new program that needs a user configuration file, is there any guidance where to put it? I could imagine creating a new dot directory ~/.myProgramName or maybe I should add it to /.config or ~/.local.
The .config directory is a newish development courtesy of XDG that seems, deservedly, to have won favour. Personally, I don't mind a dot directory of your own. A bunch of separate dot files (ala bash and various old school tools) in the toplevel of $HOME is a bit silly. Choosing a single dot file is a bad idea, be...
Where should user configuration files go? [duplicate]
1,283,688,724,000
Various Debian packages, including logrotate and rsyslog, put their own log rotation definitions in /etc/logrotate.d/ What is the correct way to override those definitions? If I modify the files, I get warnings at every system update and I risk losing the changes if I (or someone else) give the wrong answer; or risk n...
First of all, I recommend using a tool such as etckeeper to keep track of changes to files in /etc; that avoids data loss during upgrades (among other benefits). The “correct” way to override the definitions is to edit the configuration files directly; that’s why dpkg knows how to handle configuration files and prompt...
How can I properly override logrotate policies?