How do I extract login history?
You can try the last command: last john It prints out the login/out history of user john. Whereas running just last prints out the login/out history of all users.
You can try the last command: last john It prints out the login/out history of user john. Whereas running just last prints out the login/out history of all users.
The FHS provides no “standard” empty directory. It is common for Linux systems to provide a directory /var/empty, but this directory is not defined in FHS and may not actually be empty. Instead, certain daemons will create their own empty directories in here. For instance, openssh uses the empty directory /var/empty/sshd for privilege separation. If … Read more
You can get the URL of the directory you are in, as well as the Repository Root and other info by running the following command in any of the checked out directories: svn info If you want a command that returns only the URL of the repository, perhaps for use in a script, then you … Read more
The primary (historical) reasons for partitioning are: to separate the operating system from your user and application data. Until the release of RHEL 7 there was no supported upgrade path and a major version upgrade would require a re-install and then having for instance /home and other (application) data on separate partitions (or LVM volumes) … Read more
Do not mess with the mysql db. There is a lot more going on there than just the users table. Your best bet is the “SHOW GRANTS FOR” command. I have a lot of CLI maintenance aliases and functions in my .bashrc (actually my .bash_aliases that I source in my .bashrc). This function: mygrants() { … Read more
These are dynamically configured link-local addresses. They are only valid on a single network segment and are not to be routed. Of particular note, 169.254.169.254 is used in AWS, Azure and other cloud computing platforms to host instance metadata service.
You can use AllowUsers / AllowGroups if you have only a few users/groups that are allowed to login via ssh or DenyUsers / DenyGroups if you have only a few users/groups that are not allowed to login. Note that this only restricts login via ssh, other ways of login (console, ftp, …) are still possible. … Read more
I finally found the setting that was really limiting the number of connections: net.ipv4.netfilter.ip_conntrack_max. This was set to 11,776 and whatever I set it to is the number of requests I can serve in my test before having to wait tcp_fin_timeout seconds for more connections to become available. The conntrack table is what the kernel … Read more
Instead of guessing which version of RHEL a particular distro is based off, just run: rpm -E %{rhel} For Amazon Linux 2, this will give you 7.
Update 2015-02-27: This is now possible, see the answer below. Old reply: Amazon’s FAQ says it’s not possible to define a security group anywhere but at launch time.