:::: MENU ::::

Home

  • Oct 26 / 2020
  • Comments Off on MacOS – “No mountable file systems” issue when mounting ISO file
Uncategorized

MacOS – “No mountable file systems” issue when mounting ISO file

If you try to mount an ISO file (like a Linux distribution) on MacOS and you get that weird error saying “No mountable file systems“:

Then, you can easily find a workaround by using CLI.

% mkdir /mnt/iso
% hdiutil attach -nomount FILENAME.iso
/dev/disk2              FDisk_partition_scheme          
/dev/disk2s2            0xEF
% mount -t cd9660 /dev/disk2 /mnt/iso

And now, the content of your iso file is available in /mnt/iso directory.

To unmount the ISO file, just type:

% umount /mnt/iso
  • Sep 27 / 2019
  • Comments Off on MacOS – Prevent the automatic creation of a .DS_Store file on network drives
Uncategorized

MacOS – Prevent the automatic creation of a .DS_Store file on network drives

Mac OS X is automatically creating .DS_Store file as soon as you’re working on some network drives. This is used to store some custom attributes.

If you want to prevent the OS to create those files automatically, follow the steps below:

  • Open up a Terminal
  • Run this command
    defaults write com.apple.desktopservices DSDontWriteNetworkStores true
  • Restart your Mac

Once this is executed, the DS_Store files will only be created on local drives.

  • Jul 17 / 2019
  • 0
Linux

Add timestamp on each line of bash output

When analyzing the output of a bash script, it can be useful to prepend timestamp before each line to see how long it’s taking to do a specific action.

For this, you can use the ‘ts‘ command:

# echo -e "this\nis\na\ntest" | ts '[%Y-%m-%d %H:%M:%S]'
[2019-05-13 09:14:28] this
[2019-05-13 09:14:28] is
[2019-05-13 09:14:28] a
[2019-05-13 09:14:28] test

If the command ‘ts‘ is not available, you might need to install the package moreutils.

  • Apr 23 / 2019
  • Comments Off on Apache/HTTPd Permissions are missing on a component of the path
Linux

Apache/HTTPd Permissions are missing on a component of the path

Seeing that error in HTTPd/Apache logs when trying to GET some pages?

(13)Permission denied: [client xxxxx]: access to /html/myfile.html denied because search permissions are missing on a component of the path

This is because of some SELinux policies blocking the calls. If you don’t want to turn SELinux off, a simple workaround is:

chcon -R --type=httpd_sys_rw_content_t /html/
  • Feb 04 / 2019
  • Comments Off on Fix the NO_PUBKEY error with apt on Ubuntu
Linux

Fix the NO_PUBKEY error with apt on Ubuntu

When updating or installing a package on a Debian-based distribution, you can face that alert:

W: GPG error: http://ppa.launchpad.net trusty Release: The following signatures couldn't be verified because the public key is not available: NO_PUBKEY C2518248EEA14886

This just means that a signing GPG key is missing or expired on your system. The error is giving you the ID of the missing key that you can use for looking for it on the Ubuntu website:

http://keyserver.ubuntu.com:11371/pks/lookup?op=get&search=0xC2518248EEA14886

Copy the key that you just got from the website above into a file – mykey.txt, for example – and import it with the apt-key command:

apt-key add mykey.txt

Try to install/update the package again, and the error should not appear anymore.

  • Sep 27 / 2018
  • 0
Linux

Extract certificate and/or key from a PKCS12 file

The PKCS12 format is replacing the old PFX format from Microsoft. This format will allow storage of X.509 private keys and the associated public certificates in a single encrypted file.

So you can extract the key and the certificate in a single common PEM file, you can use this openssl command:

openssl pkcs12 -in myCertificate.pfx -out myCertificateAndMyKey.pem

If you want to extract the key and the certificate independently, you can also use the options nocerts/nokeys along with openssl, to extract only one part:

openssl pkcs12 -in myCertificate.pfx -nocerts -out myCertificate.key
openssl pkcs12 -in myCertificate.pfx -nokeys -out myCertificate.pem
Pages:1234567...18
Question ? Contact