Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question?
If it is not in the man pages or the how-to's this is the place! |
Notices |
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
Are you new to LinuxQuestions.org? Visit the following links:
Site Howto |
Site FAQ |
Sitemap |
Register Now
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
|
|
01-22-2006, 03:20 AM
|
#1
|
LQ Newbie
Registered: Jan 2006
Posts: 4
Rep:
|
raise ulimit help
I'm trying to raise the ulimit out of 1024, and I read a tutorial on how to do so but it locked me out of the account, I wrote:
username hard nofile 4096
username soft nofile 4096
in /etc/security/limits.conf
and that locked me out of my account.
I also changed:
#define __FD_SETSIZE 1024
to this:
#define __FD_SETSIZE 4096
..
What am I doing wrong? I'm running Mandrake Offical 10.0, any help is appreciated.
|
|
|
01-22-2006, 06:08 AM
|
#2
|
Senior Member
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873
|
I would first try to log on as your normal user, then log on as root and look at the /var/log/messages file. That could have some helpful information about your login failure.
|
|
|
01-22-2006, 11:06 AM
|
#3
|
LQ Newbie
Registered: Jan 2006
Posts: 4
Original Poster
Rep:
|
Jan 22 09:26:32 localhost sshd(pam_unix)[14765]: session opened for user depraved by (uid=501)
Jan 22 09:26:32 localhost pam_limits[14765]: setrlimit 11 to -1073753628 failed: Operation not permitted
Jan 22 09:26:32 localhost sshd[14765]: fatal: PAM session setup failed[6]: Permission denied
thats what my log said...I was told to leave the lines uncommented that I added in etc/security/limits.conf which looks like this
#<domain> <type> <item> <value>
#
#* soft core 0
#* hard rss 10000
#@student hard nproc 20
#@faculty soft nproc 20
#@faculty hard nproc 50
#ftp hard nproc 0
#@student - maxlogins 4
#depraved hard nofile 4096
#depraved soft nofile 4096
# End of file
(comments I added are in italic)
When I uncomment them, I cant relogin into the shell. But it works fine if I recomment them. But my ulimit -n still shows 1024.
Also I added session required pam_limits.so to /etc/pam.d/login, /etc/pam.d/sshd, & /etc/pam.d/su. But still the ulimit -n still shows 1024.
Am I even doing this right? basically I want my maxuser count to raise to 4096 lol, becoming quite the task for me. Any help is appreciated guys. Again i'm running Mandrake 10.0(very new to linux lol)
|
|
|
01-22-2006, 11:25 AM
|
#4
|
Senior Member
Registered: May 2004
Location: In the DC 'burbs
Distribution: Arch, Scientific Linux, Debian, Ubuntu
Posts: 4,290
|
If you leave the lines commented out, then they're not going to have any effect whatsoever. What exactly are you trying to do here? By playing with the nofile limit you're limited the max number of open files a user can have, not the maximum number of users. Is this what you mean to do? AFAIK there's no (practical) limit on the number of users that can be logged in simultaneously (well, not quite true, my RH boxes only configure 2048 pseudo-ttys so that does limit the number of login sessions, but unbless you're running a major datacenter server I would think 2000 active sessions would be plenty).
|
|
|
01-22-2006, 12:25 PM
|
#5
|
LQ Newbie
Registered: Jan 2006
Posts: 4
Original Poster
Rep:
|
I want to raise the limit of maximum users on my UnrealIRCd. And I heard to do this I would need to raise the limit on my box. I want to raise it to 4069, or atleast just learn how. So there can be a maximum of 4069 users allowed to connect to the server. Thanks for any help.
|
|
|
01-22-2006, 01:47 PM
|
#6
|
Senior Member
Registered: Dec 2005
Location: Massachusetts, USA
Distribution: Ubuntu 10.04 and CentOS 5.5
Posts: 3,873
|
btmiller,
Good job figuring out that depraved is trying to adjust the number of logins. I would never have figured that out by the first post. You must be a mind reader.
depraved,
I thought that you were logging on at the console. The messages from /var/log/messages show that you are using ssh login over the network. Also, it is clear that pam is involved. I have a lot to learn about pam. My SuSE 9.2 system has pam documentation here:
/usr/share/doc/packages/pam/html/index.html
Although it now seems that you really don't want to adjust the number of open files allowed per user, so playing with pam may or may not be relevant.
Last edited by stress_junkie; 01-22-2006 at 01:57 PM.
|
|
|
All times are GMT -5. The time now is 12:16 AM.
|
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.
|
Latest Threads
LQ News
|
|