Skip to content

how to update CA root on Centos

For RHEL 6 or later, you should be using update-ca-trust, as lzap describes in his answer below. — For older versions of Fedora, CentOS, Redhat: Curl is using the system-default CA bundle is stored in /etc/pki/tls/certs/ca-bundle.crt . Before you change it, make a copy of that file so that you can restore the system default …

How to solve (some) graphical issues with putty, UTF8, and ncurses

Hello everybody, I’m writing this article to help all those people that may have had problems with text garbled, mismatched or other kind of graphical issues with all those software that uses the famous ncurses libraries (libncurses5). It all started when I was using (via puTTY) my favorite command line log parsing tool: the great  …

How to disable automapping Exchange 2010 for all mailbox

With exchange 2010 post SP1, there’s a new feature that cause lots of problem: AUTOMAPPING With the below script you can disable all automapped mailbox   # Get all mailboxes in the forest $Mailboxes = Get-Mailbox -ResultSize unlimited -IgnoreDefaultScope -OrganizationalUnit Other $ConfirmPreference = ‘None’ # Iterate over each mailbox foreach($Mailbox in $Mailboxes) { try { …

How to decode error_reporting value

<?php $error_number = 22527; $error_description = array( ); $error_codes = array( E_ERROR => “E_ERROR”, E_WARNING => “E_WARNING”, E_PARSE => “E_PARSE”, E_NOTICE => “E_NOTICE”, E_CORE_ERROR => “E_CORE_ERROR”, E_CORE_WARNING => “E_CORE_WARNING”, E_COMPILE_ERROR => “E_COMPILE_ERROR”, E_COMPILE_WARNING => “E_COMPILE_WARNING”, E_USER_ERROR => “E_USER_ERROR”, E_USER_WARNING => “E_USER_WARNING”, E_USER_NOTICE => “E_USER_NOTICE”, E_STRICT => “E_STRICT”, E_RECOVERABLE_ERROR => “E_RECOVERABLE_ERROR”, E_DEPRECATED => “E_DEPRECATED”, E_USER_DEPRECATED => …

Script to chmod file and folder with different access

#!/bin/sh # recursive chmod with arguments for files and directories # save internal field separator IFS_save=$IFS # set internal field separator, thx to matthias IFS=$’ ‘ # read arguments chmodf=$1 # chmod for files chmodd=$2 # chmod for directories dir=$3    # start directory # test for arguments $1 and $2 if [ -z “$chmodf” -o …

How to delete snapshot with wmic

Sometimes if you try to delete shadow copy with vssadmin you will fail, in this case you can use the following procedure.   Start an elevated commandline window Type in wmic and press enter wmic:root\cli is shown Type in shadowcopy which will list the current shadow copies Type in shadowcopy delete and confirm to delete …

How to kill all connections to a SQL Server DB

Script to accomplish this, replace ‘DB_NAME’ with the database to kill all connections to: USE master GO SET NOCOUNT ON DECLARE @DBName varchar(50) DECLARE @spidstr varchar(8000) DECLARE @ConnKilled smallint SET @ConnKilled=0 SET @spidstr = ” Set @DBName = ‘DB_NAME’ IF db_id(@DBName) < 4 BEGIN PRINT ‘Connections to system databases cannot be killed’ RETURN END SELECT …