Tag Info

Hot answers tagged

19

Make the password manager run under a separate user. You can't send signals to (=kill) processes run under a different user unless you're root. All processes will still be killable by root. For closer details, see kill(2).


6

Technically, there is no way to make a process unkillable. Of course, for non-root users they can only kill processes that have the same user ID that they do, so if you can make different accounts you can use a "unique" user ID for the process and then only root could kill it. A simple, but less robust, solution is to have your process catch as many ...


3

The command groups doesn't show you all groups, it just lists all the groups the user is a member of. So if you created a group, but your user isn't a member, groups won't show it. And if you try to create the group again you get the error message.


3

You can use stat -c %w filename, it will provide the date of birth in human readable way, and -C will provide in unix timestamp. Time of birth is not supported on every filesystem; use stat -c %z, i.e. time of last change, in those cases.


3

The only way to make a process unkillable is to implement it as a kernel thread, which is not something trivial. You can still kill it but that would be an OS shutdown collateral damage.


2

With lsblk (part of the util-linux package): lsblk -d -o name,rota NAME ROTA sda 0 sdb 0 sdc 1 where ROTA means rotational device (1 if true, 0 if false)


2

$ find '.' -regextype sed -regex '-file[0-9]' To find with specific length number like -file90, -file15 $ find '.' -regextype sed -regex '-file[0-9]\{2\}' Or $ find '.' -name '-file*'


1

first things first. can you ping 192.168.56.1 ? if so then you have an IP connection to the router, set this as your default route. otherwise try pinging 192.168.56.255 (broadcast) to see on what address you might get replies. see arp -a to check what addresses you can find. can you ping 8.8.4.4 (google) after changing the default route? if so you have ...


1

Is your machine connected to a router ? wat is the Lan IP of this router ? If your pc is connected to a router the u should use the Lan IP of the router as the default gw of your pc. In your example u are using your own lan ip as your default gw.


1

What changes depends on how something is copied. Always Changes Inode - This maps the data to a physical location on disk, obviously to copy something you are creating a new file elsewhere, so the inode will be different. Using cp -p Ownership/Group - The current user will own the file (unless performing as root/sudo, then copy retains original owner). ...


1

The sequence mount ... | logger rc=$? isn't working as you expect: The return value of a pipe is the return value of the last element in that pipe. $> false | true; echo $? 0 If you use bash, try PIPESTATUS: $> false | true; echo $? ${PIPESTATUS[0]} 0 1 $> true | false; echo $? {PIPESTATUS[0]} 1 0 PIPESTATUS is a array variable. Details in ...


1

The other answers already tell you how to get this information in a number of ways , including /proc. But you must expect all these mechanisms to lie if there's any virtualisation in the way, such as a hybrid SAN array with multiple tiers, or if the Linux machine is a virtual machine (where Linux will probably report the disk as a basic SCSI rotating disk, ...



Only top voted, non community-wiki answers of a minimum length are eligible