Activate RPMFusion repo

The RPMFusion provides some free and non-free software for Fedora.

free – for Open Source Software (as defined by the Fedora Licensing Guidelines) which the Fedora project cannot ship due to other reasons

nonfree – for redistributable software that is not Open Source Software (as defined by the Fedora Licensing Guidelines); this includes software with publicly available source-code that has “no commercial use”-like restrictions

To enable access to just free repository use the following command:
root# dnf install http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm

To enable access to both the free and the nonfree repository use the following command:
root# dnf install http://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-$(rpm -E %fedora).noarch.rpm http://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-$(rpm -E %fedora).noarch.rpm

When listing a directory on an NFS share, directory listing fails half way through with ‘ls: reading directory .: Too many levels of symbolic links

Disable the dir_index filesystem feature on the filesystem that is being exported from the NFS server.

root# tune2fs -O ^dir_index /dev/sdXY, where sdXY is your device.

To re-enable the dir_index feature use the command:

root# tune2fs -O dir_index /dev/sdXY, where sdXY is your device.

Change the default Postfix queue ID to a long format.

The benefit of non-repeating names (queue ID) is simpler logfile analysis and easier queue migration. And there is nothing wrong with the default settings 😉

New queue files are created with names such as 3Pt2mN2VXxznjll. These are encoded in a 52-character alphabet that contains digits (0-9), upper-case letters (B-Z) and lower-case letters (b-z). For safety reasons the vowels (AEIOUaeiou) are excluded from the alphabet. The name format is: 6 or more characters for the time in seconds, 4 characters for the time in microseconds, the ‘z’; the remainder is the file inode number encoded in the first 51 characters of the 52-character alphabet.

How this looks now:

Jul 12 17:34:17 bnmrelay postfix/pickup[20475]: DA41A139183: uid=0 from=
Jul 12 17:34:17 bnmrelay postfix/cleanup[21313]: DA41A139183: message-id=<20160712163417.DA41A139183@bnmrelay.domain.com>
Jul 12 17:34:17 bnmrelay postfix/qmgr[30234]: DA41A139183: from=<root@bnmrelay.domain.com>, size=463, nrcpt=1 (queue active)
Jul 12 17:34:18 bnmrelay postfix/smtp[21302]: DA41A139183: to=<testaccount@domain.com>, relay=172.16.53.233[172.16.53.233]:25, delay=0.28, delays=0.05/0/0/0.23, dsn=2.6.0, status=sent (250 2.6.0 <20160712163417.DA41A139183@bnmrelay.domain.com> [InternalId=44586055500327, Hostname=BNM01.domain.com] Queued mail for delivery)
Jul 12 17:34:18 bnmrelay postfix/qmgr[30234]: DA41A139183: removed

And after the change:

Jul 12 17:34:17 bnmrelay postfix/pickup[20475]: 3rpnHt4Sgnz21N4: uid=0 from=
Jul 12 17:34:17 bnmrelay postfix/cleanup[21313]: 3rpnHt4Sgnz21N4: message-id=<20160712163417.DA41A139183@bnmrelay.domian.com>
Jul 12 17:34:17 bnmrelay postfix/qmgr[30234]: 3rpnHt4Sgnz21N4: from=<root@bnmrelay.domain.com>, size=463, nrcpt=1 (queue active)
Jul 12 17:34:18 bnmrelay postfix/smtp[21302]: 3rpnHt4Sgnz21N4: to=<testaccount@domain.com>, relay=172.16.53.233[172.16.53.233]:25, delay=0.28, delays=0.05/0/0/0.23, dsn=2.6.0, status=sent (250 2.6.0 <20160712163417.DA41A139183@bnmrelay.domain.com> [InternalId=44586055500327, Hostname=BNM01.domain.com] Queued mail for delivery)
Jul 12 17:34:18 bnmrelay postfix/qmgr[30234]: 3rpnHt4Sgnz21N4: removed

Install CUPS printer on Windows machine

The IPP is the native protocol of CUPS: Therefore no extra daemon is needed to receive IPP print jobs. The CUPS daemon listens for IPP requests on port 631. Port 631 is the default port for the IPP. Depending on its configuration it also accepts SSL-encrypted IPP, usually on the SSL-port 443. IPP clients can be other machines running Windows, GNU/Linux, Unix, or MacOS X with CUPS.

On the Windows computer, go to Control Panel->Devices and Printers and choose to ‘Add a printer’. Next, choose ‘Select a shared printer by name’ and type in the location of the printer:

ipp://hostname:631/printers/printer_queue_name

CUPS – printer in a stopped state

CUPS introduced an Error Policy which puts the CUPS printer into a stopped state when physical printers experiences an error, such as, paper jam, out of paper, paper tray open, etc. The CUPS printer does not change to an idle or ready state even after the physical problem is resolved, and the reason for this is not to drop print jobs or to send them to a printer that is not responding. The administrator must go to CUPS Web Administration or a command line to change the printer out of the stopped state. To prevent this situation change the CUPS ErrorPolicy to retry-job:

1. Enter this command at a terminal session while logged in as root:

root# /usr/sbin/lpadmin -p -o printer-error-policy=retry-job

2. Per printer – open the /etc/cups/printers.conf and find the printer that you wish to modify, and chang the ErrorPolicy entry from stop-printer to retry-job

<Printer "PrinterName">
...
ErrorPolicy retry-job

3. Globally change – open the /etc/cups/cupsd.conf and look for ErrorPolicy, if you find it, change the entry from stop-printer to retry-job.
If you do not find that entry, add the following at the end of the file:

ErrorPolicy retry-job

Or use the script below with a cron, which will automatically enables printers on a CUPS printing server:

#!/bin/sh
#
# Check if the printers are disabled and enable them.

DISABLED=`lpstat -t | grep disabled | awk ‘{ print $2 }’`

for PRINTER in $DISABLED
do
logger “Printer $PRINTER is stopped”
cupsenable -h 127.0.0.1:631 $PRINTER && logger “Printer $PRINTER has been enabled.”
done

Add the shared mailbox so it displays under your primary mailbox in Outlook Web App.

Add the shared mailbox so it displays under your primary mailbox in Outlook Web App.
This method is recommended if you want to monitor the email from your primary mailbox and the shared mailbox at the same time. In addition, after you complete this task, the shared mailbox and its folders are displayed in the left navigation pane each time you open Outlook Web App.

1. Sign in to your account in Outlook Web App.
2. Right-click your primary mailbox in the left navigation pane, and then choose add shared folder.
3. In the add shared folder dialog box, type the name or email address of the shared mailbox, and then click add.

The shared mailbox displays in your Folder list in Outlook Web App. You can expand or collapse the shared mailbox folders as you can with your primary mailbox. You also can remove the shared mailbox from your Folder list. To remove it, right-click the shared mailbox, and then click delete.

Or open the shared mailbox in a separate browser window.

1. Sign in to your account in Outlook Web App.
2. On the Outlook Web App nav bar, click on your name. A list appears.
3. Click Open another mailbox.

Type the email address of the other mailbox that you want to open. Another Outlook Web App session opens in a separate window, allowing access to the other mailbox.

List files which does not contain a string

root# grep -rL "string"

Explanation:
-r makes grep recursively
-L only output a filename when it does not contain “string”

Example:
[greg@localhost test123]$ ls -la
total 20
drwxrwxr-x. 2 greg greg 4096 Jun 2 11:31 .
drwx——. 18 greg greg 4096 Jun 2 11:30 ..
-rw-rw-r–. 1 greg greg 4 Jun 2 11:31 aaa.text
-rw-rw-r–. 1 greg greg 4 Jun 2 11:31 bbb.text
-rw-rw-r–. 1 greg greg 4 Jun 2 11:31 ccc.text
[greg@localhost test123]$ cat *
123
213
212
[greg@localhost test123]$

greg@localhost test123]$ grep -rL “123”
ccc.text
bbb.text
[greg@localhost test123]$