the following commands assume that you have the awscli command installed on your mac. if you don’t then just type in brew install awscli. having awscli auto-complete is easier than the az cli because it ships with the aws_completer command. we find the aws_completer and register it to auto-load in our .zshrc. the following command does this. restart your zsh (cmd+q) after entering this command.
(more…)Category: Linux
linux is a family of open-source Unix-like operating systems based on the linux kernel, first released on September 17, 1991, by Linus Torvalds. it is typically packaged as a distribution, which includes the kernel and supporting system software and libraries, many of them provided by the gnu project.
-
until … done loop in gnu/bash
bash has three types of loop constructs
(more…)
– for
– while
– until
until loop is used to iterate over the body of the loop till the condition stays false. -
swap file appears to have holes
error message –
(more…)root@host:~# swapon /swap-file-00 swapon: /swap-file-00: skipping - it appears to have holes. -
unexport/remove a variable in the shell
say you have assigned some value to a variable from the shell or a shell script using the export command and now you want to remove that variable, either programatically or manually.
(more…) -
list all versions of an available package using yum/dnf
dnf list <packagename> --showduplicates
(more…) -
autofs mounts
autofs is a nice traditional way to mount the nfs directories on-demand on the nfs clients. was originally used to mount the user home directories to the clients to make them sort of roaming user profiles, but this doesnt stop us from using it to configure nfs mounts in other ways. using autofs saves unnecessary resource allocation to mount the resources on a client machine, which may never be accessed in that session. it also saves the open handles on the nfs server, which is another plus.
(more…) -
selinux prevents mounted directories for serving content for httpd
error message
(13)Permission denied: [client <ipaddress>:<port>] AH00035: access to /index.html denied (filesystem path '/opt/rh/httpd24/root/var/www/html/index.html') because search permissions are missing on a component of the path
(more…) -
awk tricks
some of the awk tricks listed here. might come in handy in any of my future shell scripts.
(more…)