Installing WordPress on a FreeNAS Jail

After creating a basic jail do this:
Step 1 Configue the the Jail to Use SSH
Step 2 – Setup Apache, MySQL and PHP – NOTE: Make changes for your version of PHP
with minor changes from
Step 3 – install workpress

How to Change Authentication Method in MySQL

First, to check what is being used run this,
SELECT user, authentication_string, plugin, host FROM mysql.user;
If the user you are having issues with is set to auth_socket then you may need to change it to method with mysql_native_password
Like this,
mysql> ALTER USER 'root'@'localhost' IDENTIFIED WITH mysql_native_password BY 'password';
Change root to the user you need and set the password to whatever the password is supposed to be.

ORA-27121: unable to determine size of shared memory segment

If when you are trying to login to Oracle 10G on linux you get :

ORA-01034: ORACLE not available
ORA-27121: unable to determine size of shared memory segment
Linux Error: 13: Permission denied

This is caused by Oracle installer not setting setuid on $ORACLE_HOME/bin/oracle.
To fix do:

$ cd $ORACLE_HOME/bin
$ chmod 6751 oracle


Grid Control access to a Windows server

If you are trying to get Grid Control to access a Windows server and having trouble here’s a few things to check.

  1. Check that the host name credentials you are providing are the same as the user who install the database software on the Windows server.
  2. Check that the user is a member of the ora_dba local group on the server and
  3. Check that the Log on as a batch job local security privilege has been turned on.

Continue reading Grid Control access to a Windows server

Creating a link between two SQL servers

To create a link between two SQL Servers you need to use the sp_addlinkedserver and sp_addlinkedsrvlogin stored procedures.

sp_addlinkedserver @server='DBLINK01',@srvproduct='',@provider='SQLOLEDB',@datasrc='SQL-HOU-01';

@server is the name of the link
@srvproduct is the type of product, by default SQL Server
@datasrc is the server you link to
Then, you need to set the username and password to use on the link.

sp_addlinkedsrvlogin 'DBLINK01','false',null,'sa','Pa$$w0rd';

The first parameter is the name of the link to use,
The fourth is the account of the remote server to use,
The fifth is the password for the account.

Manually adding a mail account to SQL2005/2008

I was having trouble adding configuring Database Mail on a SQL2005 server today.
I followed the wizard just like I had done on the previous 6 servers, but this one just didn’t want to add it. It was giving me an error about not being able to insert a NULL into the server name field, although I was giving it a server name.
I tried manually adding the data into the table, but of course that didn’t work. You have to use a stored procedure.
You need to use msdb.dbo.sysmail_add_account_sp with options like below,

msdb.dbo.sysmail_add_account_sp @account_name=' mail server',@email_address='',@display_name='John Doe',@replyto_address='',@mailserver_name='',@port=25;