понедельник, 29 апреля 2019 г.

Set AD SPN record for MS SQL service account

 Source
  1. Granting read/write servicePrincipalName permissions to the service account using ADSI Edit, as described in https://support.microsoft.com/en-us/kb/811889
  2. Removing the SPNs that previously existed on the SQL Server computer account (as opposed to the service account) using

    setspn -D MSSQLSvc/HOSTNAME.domain.name.com:1234 HOSTNAME

    where 1234 was the port number used by the instance (mine was not a default instance).
 

пятница, 19 апреля 2019 г.

Linux - Kernel Semaphore parameters

Source

1 - About

On Linux, A semaphore is a System V IPC object that is used to control utilization of a particular process.
Semaphores are a shareable resource that take on a non-negative integer value. They are manipulated by the P (wait) and V (signal) functions, which decrement and increment the semaphore, respectively. When a process needs a resource, a “wait” is issued and the semaphore is decremented. When the semaphore contains a value of zero, the resources are not available and the calling process spins or blocks (as appropriate) until resources are available. When a process releases a resource controlled by a semaphore, it increments the semaphore and the waiting processes are notified.
The Semaphore Kernel parameters
Semaphore Description Minimum
SEMMSL maximum number of semaphores per array 128
SEMMNS maximum semaphores system-wide
SEMOPM maximum operations per semop call
SEMMNI maximum arrays
Advertising

3 - How to

3.1 - Display them ?

This command displays the value of the semaphore parameters:
# /sbin/sysctl -a | grep sem

3.2 - Calculate them ?

  • Calculate the minimum total semaphore requirements using the following formula:
sum (process parameters of all database instances on the system) + system and other application requirements
  • Set semmns (total semaphores systemwide) to this total.
  • Set semmsl (semaphores per set) to 256.
  • Set semmni (total semaphores sets) to semmns / semmsl rounded up to the nearest multiple of 1024.
The following formula can be used as a guide, although in practice, SEMMNS and SEMMNU can be much less than SEMMNI * SEMMSL because not every program in the system needs semaphores.
SEMMNS = SEMMNU = (SEMMNI * SEMMSL)

3.3 - Set them ?

In the file, /etc/sysctl.conf
kernel.sem = 2200 6400 200 25
Where:
kernel.sem = SEMMSL SEMMNS SEMOPM SEMMNI
Then reboot or run this command:
# /sbin/sysctl -p
Advertising

4 - Documentation / Reference