From owner-freebsd-questions Wed Apr 11 4:18:14 2001 Delivered-To: freebsd-questions@freebsd.org Received: from nyx.iam.ne.jp (nyx.iam.ne.jp [211.5.189.80]) by hub.freebsd.org (Postfix) with SMTP id 414F337B424 for ; Wed, 11 Apr 2001 04:18:08 -0700 (PDT) (envelope-from thuanan@iam.ne.jp) Received: (qmail 65779 invoked from network); 11 Apr 2001 11:18:07 -0000 Received: from unknown (HELO thuanan) (192.168.5.14) by nyx.iam.ne.jp with SMTP; 11 Apr 2001 11:18:07 -0000 Message-ID: <005201c0c278$d5f15180$0e05a8c0@iam.ne.jp> From: "Lily Moore" To: Subject: Re: Limit size of a file in FreeBSD. Date: Wed, 11 Apr 2001 20:16:20 +0900 MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="----=_NextPart_000_004E_01C0C2C4.45C830A0" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.50.4522.1200 X-MimeOLE: Produced By Microsoft MimeOLE V5.50.4522.1200 Sender: owner-freebsd-questions@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG This is a multi-part message in MIME format. ------=_NextPart_000_004E_01C0C2C4.45C830A0 Content-Type: text/plain; charset="iso-2022-jp" Content-Transfer-Encoding: 7bit I have edited /etc/login.conf at "filesize" of the "default" record like this: from ":filesize=unlimited:\" to ":filesize=1M:\" and tested OK. I couldn't upload files with size exceed 1M to my server. But I want to limit size of uploaded files to only WWW users, not to other users in my system. So I restored "filesize" of "default" record to "unlimited". Then I created a new user with login class was "wwwuser", and put "wwwuser" record into /etc/login.conf like this: wwwuser:\ :copyright=/etc/COPYRIGHT:\ :welcome=/etc/motd:\ :setenv=MAIL=/var/mail/$,BLOCKSIZE=K,FTP_PASSIVE_MODE=YES:\ :path=~/bin /bin /usr/bin /usr/local/bin /usr/X11R6/bin:\ :nologin=/var/run/nologin:\ :cputime=unlimited:\ :datasize=unlimited:\ :stacksize=unlimited:\ :memorylocked=unlimited:\ :memoryuse=unlimited:\ :filesize=1M:\ :coredumpsize=unlimited:\ :openfiles=unlimited:\ :maxproc=unlimited:\ :priority=0:\ :ignoretime@:\ :umask=022: and then do cap_mkdb /etc/login.conf But when I tested again, the user of "wwwuser"login class can upload files with size exceed 1M. Could I have any mistakes? Thank you in advanced. ----- Original Message ----- From: "Andrey Simonenko" To: "Lily Moore" Cc: Sent: Wednesday, April 11, 2001 2:58 PM Subject: Re: Limit size of a file in FreeBSD. > Check login.conf(5) manual page. There is "filesize" parameter. > > ----- Original Message ----- > From: Lily Moore > Newsgroups: lucky.freebsd.questions > Sent: 11 april 2001 C. 10:07 > Subject: Limit size of a file in FreeBSD. > > > > Does FreeBSD have any disk quota tools to limit the size of a file in > file > > system? ------=_NextPart_000_004E_01C0C2C4.45C830A0 Content-Type: text/html; charset="iso-2022-jp" Content-Transfer-Encoding: quoted-printable
  I  have edited /etc/login.conf at "filesize" of the = "default"=20 record like this:
 
  =20 from  ":filesize=3Dunlimited:\"     = to =20 ":filesize=3D1M:\"
 
and tested OK. I couldn't upload files with size exceed 1M to my = server.=20
  But I want to limit size of uploaded files to only WWW = users, not to=20 other users in my system. So I restored "filesize" = of  "default"=20 record to "unlimited". Then I created a new user with login class = was=20 "wwwuser", and put "wwwuser" record into /etc/login.conf like = this:
 
    = wwwuser:\
       =20 :copyright=3D/etc/COPYRIGHT:\
      &nbs= p;=20 :welcome=3D/etc/motd:\
       =20 :setenv=3DMAIL=3D/var/mail/$,BLOCKSIZE=3DK,FTP_PASSIVE_MODE=3DYES:\
&n= bsp;      =20 :path=3D~/bin /bin /usr/bin /usr/local/bin=20 /usr/X11R6/bin:\
       =20 :nologin=3D/var/run/nologin:\
      &nbs= p;=20 :cputime=3Dunlimited:\
       =20 :datasize=3Dunlimited:\
       =20 :stacksize=3Dunlimited:\
       =20 :memorylocked=3Dunlimited:\
       = =20 :memoryuse=3Dunlimited:\
        = :filesize=3D1M
:\
   &nb= sp;   =20 :coredumpsize=3Dunlimited:\
       = =20 :openfiles=3Dunlimited:\
       =20 :maxproc=3Dunlimited:\
       =20 :priority=3D0:\
       =20 :ignoretime@:\
        = :umask=3D022:
 
and then do

      cap_mkdb /etc/login.conf =
 
  But when I tested again, the user of "wwwuser"login=20 class can upload files with size exceed 1M. Could I have any=20 mistakes?
  Thank you in advanced.
 
 
----- Original Message -----=20
From: "Andrey Simonenko" <simon@comsys.ntu-kpi.kiev.ua= >
To: "Lily Moore" <thuanan@iam.ne.jp>
Cc: <freebsd-questions@freebsd.o= rg>
Sent: Wednesday, April 11, 2001 2:58 PM
Subject: Re: Limit size of a file in FreeBSD.

> Check login.conf(5) manual page. There is "filesize"=20 parameter.
>

> ----- Original Message -----
> From: Lily Moore = <thuanan@iam.ne.jp>
> = Newsgroups:=20 lucky.freebsd.questions
> Sent: 11 april 2001 Ç. = 10:07
> Subject:=20 Limit size of a file in FreeBSD.
>
>
> >  = Does=20 FreeBSD have any disk quota tools to limit the size of a file in
> = file
> > system?
------=_NextPart_000_004E_01C0C2C4.45C830A0-- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-questions" in the body of the message