BowerStudios.com

  • My Lab
  • Family
  • Friends
  • Professional
  • About
Home » The Lab

Linux

Primarily Debian based like Ubuntu

Extract to a different directory than current with Tar

daniel —Thu, 02/04/2021 - 2:30pm

From tecmint
# tar -xf file_name.tar -C /target/directory
# tar -xf file_name.tar.gz --directory /target/directory

  • Linux
  • Read more about Extract to a different directory than current with Tar
  • Log in to post comments

Fixing Youtube livestreams for Opera on Ubuntu

daniel —Tue, 12/01/2020 - 10:32am

This worked on Ubuntu 20.04.1 with Opera 72
Install the "Chromium Ffmpeg codecs" snap via the "Ubuntu Software" app

Then, on the command line, let's find the libffmpeg.so library that was installed by the chromium snap
$ locate libffmpeg.so
/opt/Postman/Postman-1605981456437-old/libffmpeg.so
/opt/Postman/app/libffmpeg.so
/opt/Postman.bak/app/libffmpeg.so
/snap/chromium/1399/usr/lib/chromium-browser/libffmpeg.so
/snap/chromium/1411/usr/lib/chromium-browser/libffmpeg.so
/usr/lib/slack/libffmpeg.so

We want the latest chromium one. Plug that path into the next step

$ cd /usr/lib/x86_64-linux-gnu/opera; sudo mv libffmpeg.so libffmpeg.so.bak; sudo ln -s /snap/chromium/1411/usr/lib/chromium-browser/libffmpeg.so

  • Linux
  • Read more about Fixing Youtube livestreams for Opera on Ubuntu
  • Log in to post comments

Get information about installed encrypted drives and raid drives at command line

daniel —Sat, 10/05/2019 - 10:52am

What raid devices available in config:
cat /etc/mdadm/mdadm.conf

Get details on a raid array:
sudo mdadm --detail /dev/md0
sudo mdadm --detail /dev/md/1

What drives are installed:
sudo lsblk -o NAME,FSTYPE,SIZE,MOUNTPOINT,LABEL

What luks devices setup:
sudo dmsetup status

References:

  • View available hard drives in Ubuntu
  • Setup full disk encryption on a secondary hdd in linux
  • Automatically unlock luks encrypted drives with a keyfile
  • Linux
  • Read more about Get information about installed encrypted drives and raid drives at command line
  • Log in to post comments

supervisord-restarting-and-reloading

daniel —Fri, 02/08/2019 - 10:55am

Snapshot from onurguzel.com

Supervisord is a great daemon for managing application processes. However it does not have a reload option, and restart works different than we get used to. These command makes the following effects.
service supervisor restart

Restart supervisor service without making configuration changes available. It stops, and re-starts all managed applications.
supervisorctl restart

Restart application without making configuration changes available. It stops, and re-starts the application.

If you create a new configuration. None of the commands above will make it available. If you want to apply your configuration changes in both existing and new configurations, start applications in new configurations, and re-start all managed applications, you should run:
service supervisor stop
service supervisor start

If you do not want to re-start all managed applications, but make your configuration changes available, use this command:
supervisorctl reread

This command only updates the changes. It does not restart any of the managed applications, even if their configuration has changed. New application configurations cannot be started, neither. (See the “update” command below)
supervisorctl update

Restarts the applications whose configuration has changed.
Note: After the update command, new application configurations becomes available to start, but do not start automatically until the supervisor service restarts or system reboots (even if autostart option is not disabled). In order to start new application, e.g app2, simply use the following command:
supervisorctl start app2

  • Linux
  • Read more about supervisord-restarting-and-reloading
  • Log in to post comments

Useful commands of the week

daniel —Tue, 10/17/2017 - 1:21pm

Attach the contents of 1.txt as json to send to a url:
curl --data "@1.txt" -v -H "Content-Type: application/json" https://myapp.com

Grab 10,000 lines after matching, and then look only at the given thread
grep -A 10000 "09:55:.*My API endpoint.*ProviderSearch" myLog.log | grep pool-2-thread-28166

  • Linux
  • Read more about Useful commands of the week
  • Log in to post comments

Skip recording to the Bash History

daniel —Tue, 05/02/2017 - 1:18pm

By starting the command with a " " (a space).

From: technovelty.org

  • Linux
  • Read more about Skip recording to the Bash History
  • Log in to post comments

Pretty Print Json from the command line

daniel —Wed, 04/12/2017 - 2:47pm

From: stackoverflow.com

  • Linux
  • Programming
  • Read more about Pretty Print Json from the command line
  • Log in to post comments

Wake on Lan

daniel —Mon, 02/27/2017 - 10:31am

Wake on Lan

  • Linux
  • Read more about Wake on Lan
  • Log in to post comments

HiDpi and Linux

daniel —Mon, 02/27/2017 - 10:28am

  • HiDPI
  • change dpi of screen
  • Linux
  • Read more about HiDpi and Linux
  • Log in to post comments

Grep: exclude files

daniel —Mon, 02/27/2017 - 10:23am

exclude files from grep

  • Linux
  • Read more about Grep: exclude files
  • Log in to post comments

Pages

  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • …
  • next ›
  • last »
Subscribe to RSS - Linux

Navigation

  • Search
  • Recent content
  • Contact Me
  • Mail
  • Pass Hasher
  • Bower Studios Admin

Quotes

daniel —Fri, 08/25/2006 - 10:16pm

Two hydrogen atoms meet.
One says, "I've lost my electron,"
The other says, "Are you sure?"
The first replies "Yes, I'm positive."

—

Unknown

  • Log in to post comments
  • daniel's quotes

Popular content

Last viewed:

  • See lines before and after a match with grep
  • Friends!
  • Git - Add Remote Repository
  • Antivirus
  • LDAP on Ubuntu References

Copyright 2021 Daniel Bower
  • My Lab
  • Family
  • Friends
  • Professional
  • About