EducationSoftwareStrategy.com
StrategyCommunity

Knowledge Base

Product

Community

Knowledge Base

TopicsBrowse ArticlesDeveloper Zone

Product

Download SoftwareProduct DocumentationSecurity Hub

Education

Tutorial VideosSolution GalleryEducation courses

Community

GuidelinesGrandmastersEvents
x_social-icon_white.svglinkedin_social-icon_white.svg
Strategy logoCommunity

© Strategy Inc. All Rights Reserved.

LegalTerms of UsePrivacy Policy
  1. Home
  2. Topics

KB44815: Understanding the "ulimit" and how it affects the operation of MicroStrategy Intelligence Server on Linux


Community Admin

• Strategy


This is an overview of the "ulimit" command present on Linux environments that provides mechanisms to limit and control the usage of system resources. These include file descriptors, threads, files, core dumps, and network connections. These limits can be set on a per-process and/or per-user basis.

SUMMARY
This is an overview of the "ulimit" command present on Linux environments that provides mechanisms to limit and control the usage of system resources. These include file descriptors, threads, files, core dumps, and network connections. These limits can be set on a per-process and/or per-user basis.  Careful consideration is recommended when modifying these values on any level. Examples of this command in use and it's output are provided for Linux. Potential impact of changes made via 'ulimit' on the Strategy application are also listed.
 
NOTE: Strategy Technical Support provides the following information as a courtesy to users. Note however, that Strategy Technical Support does not make recommendations related to tuning or performance of individual Strategy Intelligence Server and operating system configurations.
 
ULIMIT OVERVIEW
The 'ulimit' command is a built-in shell function, which displays and sets user level restrictions to system resources in UNIX/Linux environments. If incorrectly set, these limits can cause unexpected or undesired behaviors in Strategy Intelligence Server.  Limits that are too low can also negatively affect performance. These UserLimits prevent single users from using bottlenecking system resources, which may affect system or Strategy stability. When available, refer to the appropriate Operating System MAN (manual) page for more detailed information on the usage and syntax of the 'ulimit' command. As these values and tags may change per operating system, confirm which are appropriate for your installation. The modification of this operating system settings should be done by a qualified system administrator as it is functionality outside of the Strategy application.
 
There are two ulimit levels: A soft and hard limit. The soft limit is the value that the kernel enforces for the corresponding resource. The hard limit acts as a ceiling for the soft limit.  As such, the information displayed by the 'ulimit' command may be overridden by system/security level restrictions. Users should consult the system administrator(s) for more information on verifying system level resource restrictions.
 
NOTE: You must have root user authority to change resource hard limits.
 
CHANGING ULIMIT VALUES 
 
Use the following format to make changes to the ulimit:
 
 


Syntax:

      ulimit

Options

   -S   Change and report the soft limit associated with a resource.

   -H   Change and report the hard limit associated with a resource.

   -a   All current limits are reported

   -c   The maximum size of core files created.

   -d   The maximum size of a process's data segment.

   -f   The maximum size of files created by the shell(default option)

   -l   The maximum size that may be locked into memory.

   -m   The maximum resident set size.

   -n   The maximum number of open file descriptors.

   -p   The pipe buffer size.

   -s   The maximum stack size.

   -t   The maximum amount of cpu time in seconds.

   -u   The maximum number of processes available to a single user.

   -v   The maximum amount of virtual memory available to the process.

 
To change a value, follow this format substituting your desired value
 

ulimit -<option> <value>

For example:

ulimit -c unlimited

 
This example is to allow an unlimited size of core files to be created for use in troubleshooting. For more information, See KB13610: System settings to check to ensure that core files for the MicroStrategy Intelligence Server process are correctly created by the Linux operating system platform
 
ULIMIT EXAMPLES
The following are examples of the output of 'ulimit -a', which lists all user level restrictions. The examples below were generated using the 'ksh' shell, the output may vary when using other shell interfaces:
 
Linux

$ ulimit -a
time(cpu-seconds) unlimited

file(blocks) unlimited

coredump(blocks) unlimited

data(kbytes) unlimited

stack(kbytes) 10240

lockedmem(kbytes) 32

memory(kbytes) unlimited

nofiles(descriptors) 1024

processes 8191

 
IMPACT OF ULIMIT SETTINGS
The settings that have an "unlimited" recommendation are highlighted in bold.
 

8575
FunctionBrief DescriptionNotesDaysBetweenReturns the difference in days between two dates, as an integer. The difference is number of day boundaries crossed, not number of 24-hour periods elapsed. If the first date argument is later than the second date argument, the result is a negative number.Create a metric M01 = DaysBetween(CurrentDate(), '9/1/2004'). Use of M01 in Microsoft SQL Server 2000 would result in DATEDIFF(GetDate(), '9/1/2004').DateReturns the date portion of a date/time column. The time is truncated, not rounded.Create a metric M02 = Date(CurrentDate). Use of M02 in Microsoft SQL Server 2000 would result in CONVERT(DATETIME, CONVERT(VARCHAR(10), GETDATE(), 100)).MonthStartDateReturns the date of the first day of the month in which date or timestamp occurs.Create a metric with M03 = MonthStartDate(CurrentDate). Use of M03 in Microsoft SQL Server 2000 would result in DATEADD(DD, (1 - DAY(GetDate())), GetDate()).AddDaysReturns a date or timestamp plus an offset (+ or -) n days.Create a metric with M04 = AddDays(CurrentDate, 5). Use of M04 in Microsoft SQL Server 2000 would result in DATEADD(DD, 5, GetDate()).AddMonthsReturns a date or timestamp plus an offset (+ or -) n months. If the date does not occur in the new month, the last day of that month is returned.Create a metric with M05 = AddMonths(CurrentDate, -2). Use of M05 in Microsoft SQL Server 2000 would result in DATEADD(MM, -2, GetDate()).MonthsBetweenReturns the difference in months between two dates, as an integer. The difference is number of months elapsed, not number of month boundaries crossed. If the first date argument is later than the second date argument, the result is a negative number.Create a metric with M06 = MonthsBetween('1/3/03',CurrentDate). Use of M06 in Microsoft SQL Server 2000 would result in DATEDIFF(MM, '1/3/03', GetDate()) - CASE WHEN DAY('1/3/03') > DAY(GetDate()) THEN 1 ELSE 0 END.MonthEndDateReturns the date of the last day of the month in which date or timestamp occurs.Create a metric with M07 = MonthEndDate(CurrentDate). Use of M07 in Microsoft SQL Server 2000 would result in DATEADD(DD, -(DAY(DATEADD(MM, 1, GetDate()))), DATEADD(MM, 1, GetDate())).YearEndDateReturns the date of the last day of the year in which date or timestamp occurs.Create a metric with M08 = YearEndDate(CurrentDate). Use of M08 in Microsoft SQL Server 2000 would result in DATEADD(DD, -(DAY(GetDate())), DATEADD(MM, (13 - MONTH(GetDate())), GetDate())).YearStartDateReturns the date of the first day of the year in which date or timestamp occurs.Create a metric with M09 = YearStartDate(CurrentDate). Use of M09 in Microsoft SQL Server 2000 would result in DATEADD(MM, (1 - MONTH(GetDate())), DATEADD(DD, (1 - DAY(GetDate())), GetDate())).OptionExplanationStrategy Impact

8575
FunctionBrief DescriptionNotesDaysBetweenReturns the difference in days between two dates, as an integer. The difference is number of day boundaries crossed, not number of 24-hour periods elapsed. If the first date argument is later than the second date argument, the result is a negative number.Create a metric M01 = DaysBetween(CurrentDate(), '9/1/2004'). Use of M01 in Microsoft SQL Server 2000 would result in DATEDIFF(GetDate(), '9/1/2004').DateReturns the date portion of a date/time column. The time is truncated, not rounded.Create a metric M02 = Date(CurrentDate). Use of M02 in Microsoft SQL Server 2000 would result in CONVERT(DATETIME, CONVERT(VARCHAR(10), GETDATE(), 100)).MonthStartDateReturns the date of the first day of the month in which date or timestamp occurs.Create a metric with M03 = MonthStartDate(CurrentDate). Use of M03 in Microsoft SQL Server 2000 would result in DATEADD(DD, (1 - DAY(GetDate())), GetDate()).AddDaysReturns a date or timestamp plus an offset (+ or -) n days.Create a metric with M04 = AddDays(CurrentDate, 5). Use of M04 in Microsoft SQL Server 2000 would result in DATEADD(DD, 5, GetDate()).AddMonthsReturns a date or timestamp plus an offset (+ or -) n months. If the date does not occur in the new month, the last day of that month is returned.Create a metric with M05 = AddMonths(CurrentDate, -2). Use of M05 in Microsoft SQL Server 2000 would result in DATEADD(MM, -2, GetDate()).MonthsBetweenReturns the difference in months between two dates, as an integer. The difference is number of months elapsed, not number of month boundaries crossed. If the first date argument is later than the second date argument, the result is a negative number.Create a metric with M06 = MonthsBetween('1/3/03',CurrentDate). Use of M06 in Microsoft SQL Server 2000 would result in DATEDIFF(MM, '1/3/03', GetDate()) - CASE WHEN DAY('1/3/03') > DAY(GetDate()) THEN 1 ELSE 0 END.MonthEndDateReturns the date of the last day of the month in which date or timestamp occurs.Create a metric with M07 = MonthEndDate(CurrentDate). Use of M07 in Microsoft SQL Server 2000 would result in DATEADD(DD, -(DAY(DATEADD(MM, 1, GetDate()))), DATEADD(MM, 1, GetDate())).YearEndDateReturns the date of the last day of the year in which date or timestamp occurs.Create a metric with M08 = YearEndDate(CurrentDate). Use of M08 in Microsoft SQL Server 2000 would result in DATEADD(DD, -(DAY(GetDate())), DATEADD(MM, (13 - MONTH(GetDate())), GetDate())).YearStartDateReturns the date of the first day of the year in which date or timestamp occurs.Create a metric with M09 = YearStartDate(CurrentDate). Use of M09 in Microsoft SQL Server 2000 would result in DATEADD(MM, (1 - MONTH(GetDate())), DATEADD(DD, (1 - DAY(GetDate())), GetDate())).OptionExplanationStrategy Impact

8575
FunctionBrief DescriptionNotesDaysBetweenReturns the difference in days between two dates, as an integer. The difference is number of day boundaries crossed, not number of 24-hour periods elapsed. If the first date argument is later than the second date argument, the result is a negative number.Create a metric M01 = DaysBetween(CurrentDate(), '9/1/2004'). Use of M01 in Microsoft SQL Server 2000 would result in DATEDIFF(GetDate(), '9/1/2004').DateReturns the date portion of a date/time column. The time is truncated, not rounded.Create a metric M02 = Date(CurrentDate). Use of M02 in Microsoft SQL Server 2000 would result in CONVERT(DATETIME, CONVERT(VARCHAR(10), GETDATE(), 100)).MonthStartDateReturns the date of the first day of the month in which date or timestamp occurs.Create a metric with M03 = MonthStartDate(CurrentDate). Use of M03 in Microsoft SQL Server 2000 would result in DATEADD(DD, (1 - DAY(GetDate())), GetDate()).AddDaysReturns a date or timestamp plus an offset (+ or -) n days.Create a metric with M04 = AddDays(CurrentDate, 5). Use of M04 in Microsoft SQL Server 2000 would result in DATEADD(DD, 5, GetDate()).AddMonthsReturns a date or timestamp plus an offset (+ or -) n months. If the date does not occur in the new month, the last day of that month is returned.Create a metric with M05 = AddMonths(CurrentDate, -2). Use of M05 in Microsoft SQL Server 2000 would result in DATEADD(MM, -2, GetDate()).MonthsBetweenReturns the difference in months between two dates, as an integer. The difference is number of months elapsed, not number of month boundaries crossed. If the first date argument is later than the second date argument, the result is a negative number.Create a metric with M06 = MonthsBetween('1/3/03',CurrentDate). Use of M06 in Microsoft SQL Server 2000 would result in DATEDIFF(MM, '1/3/03', GetDate()) - CASE WHEN DAY('1/3/03') > DAY(GetDate()) THEN 1 ELSE 0 END.MonthEndDateReturns the date of the last day of the month in which date or timestamp occurs.Create a metric with M07 = MonthEndDate(CurrentDate). Use of M07 in Microsoft SQL Server 2000 would result in DATEADD(DD, -(DAY(DATEADD(MM, 1, GetDate()))), DATEADD(MM, 1, GetDate())).YearEndDateReturns the date of the last day of the year in which date or timestamp occurs.Create a metric with M08 = YearEndDate(CurrentDate). Use of M08 in Microsoft SQL Server 2000 would result in DATEADD(DD, -(DAY(GetDate())), DATEADD(MM, (13 - MONTH(GetDate())), GetDate())).YearStartDateReturns the date of the first day of the year in which date or timestamp occurs.Create a metric with M09 = YearStartDate(CurrentDate). Use of M09 in Microsoft SQL Server 2000 would result in DATEADD(MM, (1 - MONTH(GetDate())), DATEADD(DD, (1 - DAY(GetDate())), GetDate())).OptionExplanationStrategy Impact

time

The maximum number of seconds of CPU time per process.

 

If a limit must be set, Strategy suggests setting this limit to 'unlimited' to allow continuous uptime of the Intelligence Server process

file

The maximum size of files, which can be created by the shell, in 512-byte blocks.

 

Strategy suggests setting this limit to 'unlimited' to allow large files to be generated for core files and large caches.

coredump

The maximum size of core files created when a process crashes, in 512-byte blocks.

 

Strategy suggests setting this limit to 'unlimited' to allow core files to be created for use in troubleshooting.

 

KB13610:"System settings to check to ensure that core files for the Strategy Intelligence Server Universal process are correctly created by the Unix/Linux operating system platform"

data

The maximum size of a process data segment per process, in kilobytes.

 

If a limit must be set, Strategy suggests setting this limit to 'unlimited' to allow full usage of system memory. The Strategy Intelligence Server includes its own internal memory governing functionality to limit the server process memory usage.

 

KB7295: What is the Memory Contract Manager in Strategy Intelligence Server 10.x and later?

 

stack

The maximum stack size per process, in kilobytes.

 

If a limit must be applied, Strategy suggests setting this limit to the default value for the platform. Limiting the stack size stops runaway recursive function calls; however, it is possible for the Strategy Intelligence Server to legitimately require a large amount of space on the stack.

 

lockedmem

The maximum size that may be locked into memory per process, in kilobytes.

 

If this setting must be set, Strategy suggests setting it to the highest possible value.

 

memory

The maximum resident set size per process, in kilobytes.

 

Strategy suggests setting this limit to 'unlimited' to allow full usage of system memory. The Strategy Intelligence Server includes its own internal memory governing functionality to police the server process memory usage.

 

KB7295: What is the Memory Contract Manager in Strategy Intelligence Server 10.x and later? 

 

nofiles

The maximum number of open file descriptors per process.

Strategy suggests setting this limit to 65535 for Linux systems. The Strategy Intelligence Server uses file descriptors to access logs, cache and inbox files, as well as for socket descriptors (network communications).

 

KB16624: What is the 'Number of network threads' setting in Strategy Intelligence Server 8.x?

processes

The maximum number of running processes per user.

If this limit must be set, Strategy suggests that this limit be set high enough to allow the Intelligence Server and its child processes created for each database connection.

vmemory

The maximum size of virtual memory per process.

Strategy suggests setting this limit to 'unlimited' to allow full usage of system memory. The Strategy Intelligence Server includes its own internal memory governing functionality to police the server process memory usage.

 

KB7295: What is the Memory Contract Manager in Strategy Intelligence Server 8.x and later?

 
TO LEARN MORE
 
KB13610: System settings to check to ensure that core files for the Strategy Intelligence Server Universal process are correctly created by the Unix/Linux operating system platform
KB7295: What is the Memory Contract Manager in MicroStrategy Intelligence Server 8.x and later?


Comment

0 comments

Details

Knowledge Article

Published:

March 31, 2017

Last Updated:

March 31, 2017