Recent content by samuel tarcin

  1. samuel tarcin

    How to list databases from Linux command list?

    You can use mysql command like below. For more information look https://www.poftut.com/list-mysqlmariadb-databases/
  2. samuel tarcin

    Shutdown system after 3 minutes

    You can use the shutdown command + option like below. $ sudo shutdown -h +3 Reference: https://www.poftut.com/shutdown-linux-system/
  3. samuel tarcin

    Remove A User From the specific Group In Linux

    It is easier than you think. Use the usermod command with root privileges. Following example will remove the user george from the root group. $ sudo usermod -G root george Referance: https://www.poftut.com/user-groups-linux/
  4. samuel tarcin

    Run Local Script On Remote System via SSH

    It is very easy just put the script file path after the ssh command like below. ssh [email protected] 'bash -s' < cat myscript.sh Look: https://www.poftut.com/run-shell-script-command-remote-ssh/
  5. samuel tarcin

    Match for a word in a text with the PHP script

    There are different functions and ways to match a word in PHP. Best way is using preg_match() function. In the following example we will search the forum word in the $bigtext content. preg_match('/forum/',$bigtext) Look: https://www.poftut.com/check-string-contains-specific-word-php/
  6. samuel tarcin

    Copy bulk Files in Linux

    No. You shouldn’t write a bash script. Just use the cp command bulk copy feature and provide all files you want to copy and add the path which is the destination. cp file1 file2 file3 /mnt/backup Referece: https://www.poftut.com/linux-cp-or-copy-command/
  7. samuel tarcin

    Stop network service with init.d For Ubuntu

    There are different ways. You can also use the systemd but as you are asking for init.d use the following command. sudo /etc/init.d/networking start Reference: https://www.poftut.com/start-stop-restart-networking-linux/
  8. samuel tarcin

    Check Python Interpreter Version

    You can use the Python command to get the Python interpreter version. For the default Python installation use python -v OR for Python2 python2 -v Or Python3 python3 -v Reference: https://www.poftut.com/find-python-version/
  9. samuel tarcin

    check file Existing with Python Script

    Python provides exists() function which can be used like below. Look https://www.poftut.com/check-whether-file-exists-using-python/ for more information. import os.path if(os.path.exists("/etc/passwd")): print("/etc/passwd exists")
  10. samuel tarcin

    Install Nessus Vulnerability Scanner To Linux

    You have to download it from nessus web site and install it by using dpkg command and start the nessus service . reference : https://www.poftut.com/install-tenable-nessus-kali/ and https://docs.tenable.com/nessus/Content/InstallNessusLinux.htm
  11. samuel tarcin

    Listing Services with Systemctl

    There are a lot of ways to list services in a linux or ubuntu system. But if you also want to list services status "systemctl list-units" will work for your case perfectly. Ref: https://www.poftut.com/start-stop-get-status-linux-service-systemd/
  12. samuel tarcin

    Remove older backups like 1 month

    Find command is very useful option here. You can search for files older then 1 month and delete them with -delete option. $ find /tmp -mtime +7 -type f -name '*.tmp' -delete https://www.poftut.com/how-to-remove-files-older-than-1-day-1-week-1-month-recursively/
  13. samuel tarcin

    ubuntu and raspbian!

    Welcome to the nicest forum in the internet
  14. samuel tarcin

    Opened File Accessor

    There are a lot different ways to a process which is using given file. But fuser command can be used to list users who is using give n files. Fuser /home/john/test.txt will list processes wich opened test.txt file . for more details: https://www.poftut.com/use-fuser-match-user-process/
  15. samuel tarcin

    File Permission of The Sh Files

    Best way is using find command with the -exec option where you can use chmod. $ find /my/bashfiles/ -type d -name *.c -exec chmod 770 {} \; read below: https://www.poftut.com/set-permission-folders-subfolders-linux/
Top