Linux-Misc Digest #275, Volume #27                Sat, 3 Mar 01 13:13:01 EST

Contents:
  Re: { seq 1 200| less ;  } | tee foo # pls fix this (Tom Rodman)
  Re: Linux is always slow th enext morning, a cry for help! (David)
  Anyone upgraded Mandrake successfully? (Andrew Purugganan)
  RH7, Netscape and Shockwave Flash plugin problem. (Luke A. Guest)

----------------------------------------------------------------------------

Crossposted-To: comp.unix.shell,comp.unix.admin,comp.sys.sun.admin
Subject: Re: { seq 1 200| less ;  } | tee foo # pls fix this
From: [EMAIL PROTECTED] (Tom Rodman)
Date: Sat, 03 Mar 2001 17:10:40 GMT

Thanks, but the point of the "{}" block was to enclose
and log a larger script as in:

         {
                        function_to_delete_files() {
                                xargs rm -f 
                        }

                        less mylist_of_files_to_delete

                        read -p 'press any key to go > '; bar

                        function_to_delete_files <mylist_of_files_to_delete

                        echo checking for files that could not be deleted..:
                        xargs ls >/dev/null <mylist_of_files_to_delete

         } 2>&1 |tee log_of_enter_block

thanks again,

Tom

In article <[EMAIL PROTECTED]>,
J. D. Addison <[EMAIL PROTECTED]> wrote:
>Tom Rodman wrote:
>> 
>> { less longtextfile ;  : more script would go here ; } | tee foo
>> 
>> # or
>> 
>> { perl -e 'print "$i\n" while ($i++ <200);' |less ; } |tee foo
>> 
>> The above fails, in that less does not show the it's input a
>> page at a time.  Is there a clean way to fix this?
>> 
>> thanks
>> 
>> Tom
>> 
>> [EMAIL PROTECTED]
>Try 
> perl -e 'print "$i\n" while ($i++ <200);' | tee foo  |less 
>-- 
>J. D. Addison
>Telephone: 01865-246886
>email [EMAIL PROTECTED]



------------------------------

From: David <[EMAIL PROTECTED]>
Crossposted-To: 
comp.os.linux.networking,comp.os.linux,comp.os.linux.redhat,mailing.unix.samba-ntdom
Subject: Re: Linux is always slow th enext morning, a cry for help!
Date: Sat, 03 Mar 2001 17:25:10 GMT

This is a multi-part message in MIME format.
==============BC1FB3CAE1227ABA7C094668
Content-Type: text/plain; charset=us-ascii
Content-Transfer-Encoding: 7bit

Manfred Bartz wrote:
> 
> Hi Dan,
> 
> > > Did you compile from source or use a package?
> >
> > From source.
> >
> > I just downloaded qmail-1.03.tar.gz and followed his instructions
> > on a Red Hat 6.2 system.
> > Right off the bat, his instructions produce an error:
> >   useradd: cannot create directory /var/qmail/alias
> 
> Hmm, did you create the necessary qmail user accounts before compiling
> the source?  The whole procedure is actually is quite well explained
> but without redundancy.  ;)  You really need to make sure you fully
> understand each step and then implement it before you go on to the
> next step.  First time I did it I had problems too.  :/
> 
> > Normally, I'd dig in and try to figure out what to do, but
> > his style is so cr.yp.tic that it's discouraging.  The man
> > has a serious attitude.
> 
> I'd have to agree that DJB is not the easiest personality to get along
> with.  However, the software he produces is outstanding.  In the end
> it is up to the sysadmin to decide if the quality of the solution
> outweighs the issues one might have with the attitudes of the author.
> 
> One of the main issues a lot of people have with DJB's software is
> where the author mandates it must be located.  Personally, I don't
> have an issue with that.  I also believe that the FSH is something
> I don't need to religiously follow; well, I actually think the FSH
> creates more problems than it solves.


Since it is a redhat 6.2 system you might find this ".spec" file to be
of help. It does almost everything except some of the configuration
files.



-- 
Confucius say: He who play in root, eventually kill tree.
Registered with the Linux Counter.  http://counter.li.org
ID # 123538
Completed more W/U's than 99.086% of seti users. +/- 0.01%
==============BC1FB3CAE1227ABA7C094668
Content-Type: text/plain; charset=us-ascii;
 name="qmail.spec"
Content-Transfer-Encoding: 7bit
Content-Disposition: inline;
 filename="qmail.spec"

Name: qmail
Version: 1.03
Release: 17
Group: Utilities/System
URL: http://www.qmail.org/
Copyright: Check with [EMAIL PROTECTED]
Source0: ftp://koobera.math.uic.edu/pub/software/qmail-1.03.tar.gz
Source1: ftp://koobera.math.uic.edu/pub/software/dot-forward-0.71.tar.gz
Source2: ftp://koobera.math.uic.edu/pub/software/fastforward-0.51.tar.gz
Source3: ftp://koobera.math.uic.edu/pub/software/rblsmtpd-0.70.tar.gz
Source5: qmail-1.03-linux.init
Source6: qmail-1.03-solaris.init
Source7: qmail-linux.sh
Source8: qmail-linux.csh
Source9: qmail-aliases
Source10: qmail-default
Source11: qmail-msglog
Source12: qmail-default-delivery
Source13: brand.c
Source14: auto_uids.c
Source15: xinetd.smtp
Source16: xinetd.qmqp
Source17: xinetd.ssmtp
Patch0: qmail-1.03.install.patch
Patch1: qmail-1.03.msglog.patch
Patch2: qmail-1.03.redhat.patch
Patch3: qmail-1.03.solaris.patch
Patch4: qmail-1.03.ids.patch
Patch5: qmail-1.03.rbl.conf.patch
Patch6: qmail-1.03-mfcheck.3.patch
Summary: qmail Mail Transport Agent
Buildroot: %{_tmppath}/%{name}-%{version}-%{release}
Provides: MTA smtpdaemon qmailmta qmail-server
%ifos Linux
Requires: chkconfig shadow-utils tcp_wrappers
%else
Requires: tcp_wrappers
%endif
Conflicts: sendmail qmail-client
ExclusiveOS: linux solaris
Packager: [EMAIL PROTECTED]
%description
qmail is a small, fast, secure replacement for the SENDMAIL package, which is
the program that actually receives, routes, and delivers electronic mail.

The dot-forward and fastforward packages have been added to this distribution
for (not 100%) SENDMAIL compatability.

The rblsmtpd package has been added as an optional way to fight SPAM.

*** Note: Be sure and read the documentation as there are some small but very
significant differences between SENDMAIL and QMAIL and the programs that
interact with them.

A sub-package, qmail-msglog, adds (configurable) message logging.  This has been
added as a sub-package since this necessarily slows things down a little bit and
the author feels it necessary to distinguish the added capability as an add-on
package.

An alternative package (smaller, easier to configure) is the qmail-client
package which will ONLY work on a LAN connected to the qmail mail server via
the QMQP protocol.

%package msglog
Requires: qmail
Summary: qmail Mail Transport Agent with Message Logging
Group: Utilities/System
%description msglog
qmail-msglog adds a (customizable) script that runs on each and every message
that goes through the mail system.  One usage example is to record Message IDs
in the log file.

%package client
Group: Utilities/System
Summary: qmail Mail Transport Agent
Provides: MTA smtpdaemon qmailmta
%description client
qmail-client is a small, fast, secure replacement for the SENDMAIL package,
which is the program that actually receives, routes, and delivers electronic
mail.

*** Note: This package is for a client only and REQUIRES the main qmail server
on a connected LAN.

*** Note: Be sure and read the documentation as there are some small but very
significant differences between SENDMAIL and QMAIL and the programs that
interact with them.

%changelog
* Sat Sep 30 2000 David Summers <[EMAIL PROTECTED]>
  Release 17: Updated to work with Redhat 7.0 (and previous releases).
  Should work with Solaris but not yet tested.
  Now requires tcp_wrappers.
  Added "restart" and "flush" to /etc/init.d/qmail script.
  Added SSMTP (SSL SMTP). (Won't work without XINETD and STUNNEL).

* Thu Apr 06 2000 David Summers <[EMAIL PROTECTED]>
  Release 16:
  Finally added /usr/lib/sendmail to be more sendmail compatible on Linux.

* Sun Mar 19 2000 David Summers <[EMAIL PROTECTED]>
  Release 15:
  Fixed verify for different files.

* Thu Mar 16 2000 David Summers <[EMAIL PROTECTED]>
- Release 14:
  Added "." to /var/qmail/users/assign so qmail-newu won't give error.
  (Thanks to [EMAIL PROTECTED])

* Tue Feb 08 2000 David Summers <[EMAIL PROTECTED]>
- Release 13:
  Changed "%ifos Solaris" to "%ifnos Linux".

* Mon Feb 07 2000 David Summers <[EMAIL PROTECTED]>
- Release 12:
  Verified operation on Solaris. /etc/aliases already exists so don't treat it
     as a config file.

* Sun Feb 06 2000 David Summers <[EMAIL PROTECTED]>
- Release 11:
  Added mfcheck optional spam patch.
  Took out extra Solaris init scripts.

* Sun Nov 28 1999 David Summers <[EMAIL PROTECTED]>
- Release 10:
  Finally got around to adding newaliases link.
  Only copy aliases file for Linux because Solaris already has it.
  Fixed silly setting of files to qmail group (in docs and others).

* Thu Jul 08 1999 David Summers <[EMAIL PROTECTED]>
- Release 9: Ouch! RPM 3.0 changed from OS=SunOS to OS=solaris.

* Sat Jun 26 1999 David Summers <[EMAIL PROTECTED]>
Release 8:
- Fixed to work with LinuxPPC Release 5, don't need "ppc patch" anymore, but brand had 
to change.
- Changed "install" to not require building by root.
- Changed (/etc/rc.d/init.d/qmail) to use Linux "chkconfig".
- Changed file unpacking to be silent.

* Tue Sep 01 1998 David W. Summers <[EMAIL PROTECTED]>

Release 7:
- Patch to work with MkLinux DR3 and LinuxPPC Release 4.

* Wed Aug 26 1998 David W. Summers <[EMAIL PROTECTED]>

Release 6:
- Changed rblsmtpd to optionally print logging information so by default it
won't print out to the SMTP socket when used with INETD.

* Mon Aug 24 1998 David W. Summers <[EMAIL PROTECTED]>

Release 5:
- Changed to rblsmtpd-0.70 package.

* Fri Aug 14 1998 David W. Summers <[EMAIL PROTECTED]>

Release 4:
- Added rblsmtpd-0.50 package.
- Fixed dot-forward and fast forward packages not to complain while compiling on
  Solaris.
- Added documentation that qmail install didn't get.

* Wed Aug 05 1998 David W. Summers <[EMAIL PROTECTED]>

Release 3:
- Added dot-forward-0.71 package.
- Added fastforward-0.51 package.

* Fri Jun 19 1998 David W. Summers <[EMAIL PROTECTED]>

Release 2:
- Now creates backups of /etc/inetd.conf and /etc/services files.
- Fixed problem with wiping out /etc/services caused by misplaced parenthesis.

* Mon Jun 15 1998 David W. Summers <[EMAIL PROTECTED]>

Release 1:
- conf-patrn flip-flopped from 1.02 to 1.03, hence qmail-1.03.solaris.patch.
- Started with qmail-1.03 sources and qmail-1.02-9.spec file.

#
# MACROS
#
# Find users and groups and brand files with uids and gids.
# Set permissions, owners and groups
%define brand cd /var/qmail/bin; ./brand install instcheck qmail-lspawn qmail-queue 
qmail-rspawn qmail-showctl qmail-start; /var/qmail/bin/install -d

# Error message if users or groups already exist
%define user_group_error (echo "Error $? : Required user or group already exists, 
please check /etc/passwd, /etc/group, and /etc/shadow files."; exit 1)

%prep
# QMAIL 1.03 Package
%setup -q
# DOT FORWARD Package
%setup -q -D -T -a 1
# FAST FORWARD Package
%setup -q -D -T -a 2
# RBLSMTPD Package
%setup -q -D -T -a 3

# Fix install
%patch0 -p1

%ifos Linux
# RedHat patch
%patch2 -p1
%else
# Solaris patch
%patch3 -p1
%endif

# IDs patch
%patch4 -p1

# RBL conf patch.
%patch5 -p0

# MFCHECK patch.
%patch6 -p1

%build
cp $RPM_SOURCE_DIR/brand.c .
cp $RPM_SOURCE_DIR/auto_uids.c .
make
mv qmail-queue qmail-queue.orig
patch -p1 < $RPM_SOURCE_DIR/qmail-1.03.msglog.patch
make
mv qmail-queue qmail-queue.msglog
mv qmail-queue.orig qmail-queue
./compile -g brand.c
./load brand
make man

# DOT FORWARD
(cd dot-forward-0.71
make)

# FAST FORWARD
(cd fastforward-0.51
make)

# RBLSMTPD
(cd rblsmtpd-0.70
make)

%install
%ifos Linux
extra=rc.d
%endif
/bin/rm -rf $RPM_BUILD_ROOT
mkdir -p $RPM_BUILD_ROOT/etc/xinetd.d
mkdir -p $RPM_BUILD_ROOT/etc/qmail/alias
mkdir -p $RPM_BUILD_ROOT/etc/qmail/control
mkdir -p $RPM_BUILD_ROOT/etc/qmail/users
mkdir -p $RPM_BUILD_ROOT/usr/bin/qmail
mkdir -p $RPM_BUILD_ROOT/usr/doc/qmail-1.03
mkdir -p $RPM_BUILD_ROOT/usr/lib/qmail/boot
mkdir -p $RPM_BUILD_ROOT/usr/man
mkdir -p $RPM_BUILD_ROOT/var/qmail
chmod 755 $RPM_BUILD_ROOT/var/qmail
ln -sf ../../etc/qmail/alias $RPM_BUILD_ROOT/var/qmail
ln -sf ../../usr/lib/qmail/boot $RPM_BUILD_ROOT/var/qmail/boot
ln -sf ../../etc/qmail/control $RPM_BUILD_ROOT/var/qmail
ln -sf ../../etc/qmail/users $RPM_BUILD_ROOT/var/qmail
ln -sf ../../usr/doc/qmail-1.03 $RPM_BUILD_ROOT/var/qmail/doc
ln -sf ../../usr/bin/qmail $RPM_BUILD_ROOT/var/qmail/bin
ln -sf ../../usr/man $RPM_BUILD_ROOT/var/qmail/man
# Save old Install and Check
mv install install.old
mv instcheck instcheck.old
# Fix Install and Check
sed "s;/var/qmail;$RPM_BUILD_ROOT/var/qmail;" conf-qmail > conf-qmail.tmp
mv conf-qmail.tmp conf-qmail
# Compile Install and Check
make install instcheck
# INSTALL IT
./install -c
# Check it
#./instcheck
# Move old versions of Install and Check back
mv install.old install
mv instcheck.old instcheck
cp qmail-queue.msglog $RPM_BUILD_ROOT/var/qmail/bin

# Copy documentation that qmail install didn't get.
cp BLURB* README SECURITY THANKS THOUGHTS TODO VERSION $RPM_BUILD_ROOT/var/qmail/doc

# Sendmail compatable fix for user to see mail queue
ln -s qmail/qmail-qread $RPM_BUILD_ROOT/usr/bin/mailq

# Set up post installation programs
cp ./brand ./install ./instcheck ./config ./config-fast ./dnsfq ./dnsip ./dnsptr 
./hostname ./ipmeprint $RPM_BUILD_ROOT/var/qmail/bin

# Set up boot procedures
%ifos Linux
mkdir -p $RPM_BUILD_ROOT/etc/rc.d/init.d
%else
(mkdir -p $RPM_BUILD_ROOT/etc/$extra; cd $RPM_BUILD_ROOT/etc/$extra;
mkdir -p init.d rc3.d
)
%endif

%ifos Linux
mkdir -p $RPM_BUILD_ROOT/etc/profile.d
cp $RPM_SOURCE_DIR/qmail-linux.sh $RPM_BUILD_ROOT/etc/profile.d/qmail.sh
cp $RPM_SOURCE_DIR/qmail-linux.csh $RPM_BUILD_ROOT/etc/profile.d/qmail.csh
chmod a+x $RPM_BUILD_ROOT/etc/profile.d/qmail*
cp $RPM_SOURCE_DIR/qmail-1.03-linux.init $RPM_BUILD_ROOT/etc/$extra/init.d/qmail
%else
cp $RPM_SOURCE_DIR/qmail-1.03-solaris.init $RPM_BUILD_ROOT/etc/$extra/init.d/qmail
%endif
chmod a+x $RPM_BUILD_ROOT/etc/$extra/init.d/qmail
%ifnos Linux
ln -sf ../init.d/qmail $RPM_BUILD_ROOT/etc/$extra/rc3.d/K30qmail
ln -sf ../init.d/qmail $RPM_BUILD_ROOT/etc/$extra/rc3.d/S80qmail
%endif

%ifos Linux
mkdir -p $RPM_BUILD_ROOT/usr/sbin
mkdir -p $RPM_BUILD_ROOT/usr/lib
(cd $RPM_BUILD_ROOT/usr/sbin;
ln -sf ../../var/qmail/bin/sendmail;
cd $RPM_BUILD_ROOT/usr/lib;
ln -sf ../../var/qmail/bin/sendmail;
cd $RPM_BUILD_ROOT/usr/bin;
ln -s ../../var/qmail/bin/newaliases
)
%else
mkdir -p $RPM_BUILD_ROOT/usr/lib
(cd $RPM_BUILD_ROOT/usr/lib;
ln -sf ../../var/qmail/bin/sendmail;
cd $RPM_BUILD_ROOT/usr/bin;
ln -sf ../../var/qmail/bin/newaliases
)
%endif

# Set up mailing aliases (Solaris already has these so we don't copy)
%ifos Linux
cp $RPM_SOURCE_DIR/qmail-aliases $RPM_BUILD_ROOT/etc/aliases
%endif
(cd $RPM_BUILD_ROOT/etc/qmail/alias;
touch .qmail-root;
cp $RPM_SOURCE_DIR/qmail-msglog  .qmail-msglog
cp $RPM_SOURCE_DIR/qmail-default .qmail-default
chmod 644 .qmail*
)

# Set up control files.
(cd $RPM_BUILD_ROOT/etc/qmail/control;
touch defaultdomain locals me plusdomain qmqpservers rcpthosts;
chmod 644 defaultdomain locals me plusdomain qmqpservers rcpthosts;
)

# Set up blank qmail/users
(cd $RPM_BUILD_ROOT/etc/qmail/users;
touch assign include exclude mailnames subusers append
echo "." > assign
)

# Set up default delivery
cp $RPM_SOURCE_DIR/qmail-default-delivery $RPM_BUILD_ROOT/etc/qmail/dot-qmail

# DOT FORWARD command and doc
cp dot-forward-0.71/dot-forward $RPM_BUILD_ROOT/var/qmail/bin
cp dot-forward-0.71/dot-forward.1 $RPM_BUILD_ROOT/var/qmail/man/man1

# FAST FORWARD commands and docs
cp fastforward-0.51/fastforward $RPM_BUILD_ROOT/var/qmail/bin
cp fastforward-0.51/newaliases $RPM_BUILD_ROOT/var/qmail/bin
cp fastforward-0.51/newinclude $RPM_BUILD_ROOT/var/qmail/bin
cp fastforward-0.51/printforward $RPM_BUILD_ROOT/var/qmail/bin
cp fastforward-0.51/printmaillist $RPM_BUILD_ROOT/var/qmail/bin
cp fastforward-0.51/setforward $RPM_BUILD_ROOT/var/qmail/bin
cp fastforward-0.51/setmaillist $RPM_BUILD_ROOT/var/qmail/bin

cp fastforward-0.51/fastforward.1 $RPM_BUILD_ROOT/var/qmail/man/man1
cp fastforward-0.51/newaliases.1 $RPM_BUILD_ROOT/var/qmail/man/man1
cp fastforward-0.51/newinclude.1 $RPM_BUILD_ROOT/var/qmail/man/man1
cp fastforward-0.51/printforward.1 $RPM_BUILD_ROOT/var/qmail/man/man1
cp fastforward-0.51/printmaillist.1 $RPM_BUILD_ROOT/var/qmail/man/man1
cp fastforward-0.51/setforward.1 $RPM_BUILD_ROOT/var/qmail/man/man1
cp fastforward-0.51/setmaillist.1 $RPM_BUILD_ROOT/var/qmail/man/man1

cp fastforward-0.51/ALIASES $RPM_BUILD_ROOT/usr/doc/qmail-1.03

# RBLSMTPD commands and doc
cp rblsmtpd-0.70/antirbl $RPM_BUILD_ROOT/var/qmail/bin
cp rblsmtpd-0.70/antirbl.8 $RPM_BUILD_ROOT/var/qmail/man/man8
cp rblsmtpd-0.70/rblsmtpd $RPM_BUILD_ROOT/var/qmail/bin
cp rblsmtpd-0.70/rblsmtpd.8 $RPM_BUILD_ROOT/var/qmail/man/man8

# Add rc boot script
echo "#! /bin/sh" > $RPM_BUILD_ROOT/var/qmail/rc
echo "/etc/$extra/init.d/qmail start" >> $RPM_BUILD_ROOT/var/qmail/rc
chmod a+rx $RPM_BUILD_ROOT/var/qmail/rc

# Add xinetd configuration.
cp %{SOURCE15} $RPM_BUILD_ROOT/etc/xinetd.d/smtp
cp %{SOURCE16} $RPM_BUILD_ROOT/etc/xinetd.d/qmqp
cp %{SOURCE17} $RPM_BUILD_ROOT/etc/xinetd.d/ssmtp

%pre
# qmail Pre-install script.
# If package is being installed for the first time
if [ $1 = 1 ]; then

%ifnos Linux
# set differnet INET directory for Solaris
INET=inet

# Stop sendmail and try to clear mail queue.
/etc/init.d/sendmail stop

if [ -f /usr/lib/sendmail ]; then
   /usr/lib/sendmail -q -v > /tmp/qmail.install.$$.log 2>&1
   #echo "Saving /usr/lib/sendmail"
   mv /usr/lib/sendmail /usr/lib/sendmail.pre.qmail
fi

if [ -f /etc/mail/sendmail.cf ]; then
   #echo "Saving /etc/mail/sendmail.cf"
   mv /etc/mail/sendmail.cf /etc/mail/sendmail.cf.pre.qmail
fi
%endif

groupadd nofiles || %{user_group_error};
useradd -g nofiles -d /var/qmail qmaild || %{user_group_error};
useradd -g nofiles -d /var/qmail qmaill || %{user_group_error};
useradd -g nofiles -d /var/qmail qmailp || %{user_group_error};
useradd -g nofiles -d /var/qmail/alias alias || %{user_group_error};
groupadd qmail || %{user_group_error};
useradd -g qmail -d /var/qmail qmailq || %{user_group_error};
useradd -g qmail -d /var/qmail qmailr || %{user_group_error};
useradd -g qmail -d /var/qmail qmails || %{user_group_error};

%ifos Linux
# Remove files put there by useradd.
rm -rf /var/qmail/.[a-zA-Z]*
rm -rf /var/qmail/*

chmod a+r /var/qmail
chown alias /var/qmail
# Because it is a symbolic link.
rm -rf /var/qmail/alias
%endif

if [ ! -d /etc/xinetd.d ]; then
   g=`grep -c "qmail" /etc/$INET/inetd.conf || true`
   if [ $g -gt 0 ]; then # If already installed.
      true; # echo "qmail already installed in /etc/$INET/inetd.conf, no need to add."
    else # Not already installed
      (cat /etc/$INET/inetd.conf;
      echo "#smtp       stream  tcp     nowait  qmaild  /usr/sbin/tcpd 
/var/qmail/bin/tcp-env /var/qmail/bin/qmail-smtpd";
      echo "#qmqp       stream  tcp     nowait  qmaild  /usr/sbin/tcpd 
/var/qmail/bin/tcp-env /var/qmail/bin/qmail-qmqpd") > /etc/$INET/inetd.conf.$$ && \
         mv /etc/$INET/inetd.conf /etc/$INET/inetd.conf.bak && \
         mv /etc/$INET/inetd.conf.$$ /etc/$INET/inetd.conf
   fi # Already installed
fi # xinetd

#echo "Adding qmqp to /etc/$INET/services"
g=`grep -c ^qmqp /etc/$INET/services` || true
if [ $g -le 0 ]; then
   (cat /etc/$INET/services;
   echo "qmqp           628/tcp         qmqp            # QMAIL Queuing Protocol") > 
/etc/$INET/services.$$ && \
      mv /etc/$INET/services /etc/$INET/services.bak && \
      mv /etc/$INET/services.$$ /etc/$INET/services
fi # services

fi # End Package installed for first time.

%post
# qmail Post-install script
%ifos Linux
# Set up start up routines
/sbin/chkconfig --add qmail
%endif

# Brand with correct UID, GID.
%{brand}
#/var/qmail/bin/instcheck

# Set file permissions.
chown alias:qmail /etc/qmail/alias

# Set for user access.
chmod u+s /var/qmail/bin/qmail-qread

# Run configuration script.
./config >> /tmp/qmail.install.$$.log 2>&1

# Set up aliases
/var/qmail/bin/newaliases

%preun
# qmail Pre-uninstall script.
%ifos Linux
extra=rc.d
%else
# Set different INET directory for Solaris.
INET=inet
%endif
if [ -f /etc/$extra/init.d/qmail ]; then
        /etc/$extra/init.d/qmail stop
fi

# If package is being erased for the last time.
if [ $1 = 0 ]; then
   if [ ! -d /etc/xinetd.d ]; then
      #echo "Removing qmail from /etc/$INET/inetd.conf"
      sed -e '/qmail/d' /etc/$INET/inetd.conf > /etc/$INET/inetd.conf.$$ && \
         mv /etc/$INET/inetd.conf /etc/$INET/inetd.conf.bak && \
         mv /etc/$INET/inetd.conf.$$ /etc/$INET/inetd.conf
   fi

   sed -e '/qmqp/d' /etc/$INET/services > /etc/$INET/services.$$ && \
      mv /etc/$INET/services /etc/$INET/services.bak && \
      mv /etc/$INET/services.$$ /etc/$INET/services
   # Need to kill -HUP inetd

   # Delete qmail users
   userdel alias    || true;
   userdel qmaild   || true;
   userdel qmailq   || true;
   userdel qmailr   || true;
   userdel qmails   || true;
   userdel qmaill   || true;
   userdel qmailp   || true;

   # Delete qmail groups
   groupdel qmail   || true;
   groupdel nofiles || true;

%ifos Linux
   /sbin/chkconfig --del qmail
%endif

fi

%postun
# qmail Post-uninstall script.
%ifnos Linux
# If package is being un-installed for last time.
if [ $1 = 0 ]; then
if [ -f /usr/lib/sendmail.pre.qmail ]; then
   #echo "Restore /usr/lib/sendmail"
   mv /usr/lib/sendmail.pre.qmail /usr/lib/sendmail
fi

if [ -f /etc/mail/sendmail.cf.pre.qmail ]; then
   #echo "Restore /etc/mail/sendmail.cf"
   mv /etc/mail/sendmail.cf.pre.qmail /etc/mail/sendmail.cf
fi
# End if package is being un-installed for last time.
fi
%endif

%pre msglog
# qmail-msglog Pre-install script.
%ifos Linux
extra=rc.d
%endif
/etc/$extra/init.d/qmail stop

%post msglog
# qmail-msglog Post-install script.
cd /var/qmail/bin
mv qmail-queue qmail-queue.pre.msglog
cp qmail-queue.msglog qmail-queue
%{brand}
#/var/qmail/bin/instcheck

%preun msglog
# qmail-msglog Pre-uninstall script.
if [ -f /usr/bin/qmail/qmail-queue.pre.msglog ]; then
   cd /usr/bin/qmail
   mv qmail-queue.pre.msglog qmail-queue
fi

%pre client
# qmail-client Pre-install script.
%ifnos Linux
# If package is being installed for the first time
if [ $1 = 1 ]; then
# Stop sendmail and try to clear mail queue.
/etc/init.d/sendmail stop

if [ -f /usr/lib/sendmail ]; then
   /usr/lib/sendmail -q -v > /tmp/qmail.install.$$.log 2>&1
   #echo "Saving /usr/lib/sendmail"
   mv /usr/lib/sendmail /usr/lib/sendmail.pre.qmail
fi

if [ -f /etc/mail/sendmail.cf ]; then
   #echo "Saving /etc/mail/sendmail.cf"
   mv /etc/mail/sendmail.cf /etc/mail/sendmail.cf.pre.qmail
fi
# End Package installed for first time.
fi
%endif

%post client
# qmail-client Post-install script.
# Run configuration script.
cd /var/qmail/bin
# Set up for QMAIL CLIENT
rm qmail-queue
ln -sf qmail-qmqpc qmail-queue
# Configure client control files.
./config >> /tmp/qmail.install.$$.log 2>&1
# Remove unneeded control files generated by config
rm /etc/qmail/control/locals
rm /etc/qmail/control/rcpthosts

%postun client
# qmail-client Post-uninstall script.
%ifnos Linux
# If package is being un-installed for last time.
if [ $1 = 0 ]; then
if [ -f /usr/lib/sendmail.pre.qmail ]; then
   #echo "Restore /usr/lib/sendmail"
   mv /usr/lib/sendmail.pre.qmail /usr/lib/sendmail
fi

if [ -f /etc/mail/sendmail.cf.pre.qmail ]; then
   #echo "Restore /etc/mail/sendmail.cf"
   mv /etc/mail/sendmail.cf.pre.qmail /etc/mail/sendmail.cf
fi
# End if package is being un-installed for last time.
fi
%endif

%clean
# Clean up after compiling and installing.
#rm -rf $RPM_BUILD_ROOT

%files
# qmail package file list.
%defattr(-,root,root)
%ifos Linux
%config /etc/aliases
%endif
%config /etc/qmail/alias/.qmail-root
%config /etc/qmail/alias/.qmail-default
%config /etc/qmail/dot-qmail
%config /etc/qmail/control/defaultdomain
%config /etc/qmail/control/locals
%config /etc/qmail/control/me
%config /etc/qmail/control/plusdomain
%config /etc/qmail/control/rcpthosts
%config /etc/xinetd.d/smtp
%config /etc/xinetd.d/qmqp
%config /etc/xinetd.d/ssmtp
%verify(not group) %config /etc/qmail/users
%ifos Linux
%config /etc/profile.d/*
%endif
%docdir /usr/doc/qmail-1.03
%docdir /usr/man
%ifos Linux
/etc/rc.d/init.d/qmail
%else
/etc/init.d/qmail
/etc/rc3.d/K30qmail
/etc/rc3.d/S80qmail
%endif
/usr/bin/mailq
/usr/bin/newaliases
/usr/bin/qmail/brand
/usr/bin/qmail/bouncesaying
/usr/bin/qmail/condredirect
/usr/bin/qmail/config
/usr/bin/qmail/config-fast
/usr/bin/qmail/datemail
/usr/bin/qmail/dnsfq
/usr/bin/qmail/dnsip
/usr/bin/qmail/dnsptr
/usr/bin/qmail/dot-forward
/usr/bin/qmail/elq
/usr/bin/qmail/except
/usr/bin/qmail/forward
/usr/bin/qmail/hostname
%verify(not md5 mtime) /usr/bin/qmail/install
%verify(not md5 mtime) /usr/bin/qmail/instcheck
/usr/bin/qmail/ipmeprint
/usr/bin/qmail/maildir2mbox
/usr/bin/qmail/maildirmake
/usr/bin/qmail/maildirwatch
/usr/bin/qmail/mailsubj
/usr/bin/qmail/pinq
/usr/bin/qmail/predate
/usr/bin/qmail/preline
/usr/bin/qmail/qail
/usr/bin/qmail/qbiff
/usr/bin/qmail/qmail-clean
/usr/bin/qmail/qmail-getpw
/usr/bin/qmail/qmail-inject
/usr/bin/qmail/qmail-local
%verify(not md5 mtime) /usr/bin/qmail/qmail-lspawn
/usr/bin/qmail/qmail-newmrh
/usr/bin/qmail/qmail-newu
/usr/bin/qmail/qmail-pop3d
/usr/bin/qmail/qmail-popup
/usr/bin/qmail/qmail-pw2u
/usr/bin/qmail/qmail-qmqpc
/usr/bin/qmail/qmail-qmqpd
/usr/bin/qmail/qmail-qmtpd
%verify(not mode) /usr/bin/qmail/qmail-qread
/usr/bin/qmail/qmail-qstat
%verify(not md5 user mtime) /usr/bin/qmail/qmail-queue
/usr/bin/qmail/qmail-remote
%verify(not md5 mtime) /usr/bin/qmail/qmail-rspawn
/usr/bin/qmail/qmail-send
%verify(not md5 mtime) /usr/bin/qmail/qmail-showctl
/usr/bin/qmail/qmail-smtpd
%verify(not md5 mtime) /usr/bin/qmail/qmail-start
/usr/bin/qmail/qmail-tcpok
/usr/bin/qmail/qmail-tcpto
/usr/bin/qmail/qreceipt
/usr/bin/qmail/qsmhook
/usr/bin/qmail/sendmail
/usr/bin/qmail/splogger
/usr/bin/qmail/tcp-env
/usr/bin/qmail/fastforward
/usr/bin/qmail/newaliases
/usr/bin/qmail/newinclude
/usr/bin/qmail/printforward
/usr/bin/qmail/printmaillist
/usr/bin/qmail/setforward
/usr/bin/qmail/setmaillist
/usr/bin/qmail/antirbl
/usr/bin/qmail/rblsmtpd
%dir /usr/bin/qmail
%ifos Linux
/usr/sbin/sendmail
%endif
/usr/lib/sendmail
/usr/doc/qmail-1.03
/usr/man/man*/*
/usr/lib/qmail/*
/var/qmail/alias
/var/qmail/bin
/var/qmail/boot
/var/qmail/control
/var/qmail/doc
/var/qmail/man
# queue left out on purpose as it is ALWAYS going to be different and non-verifiable.
/var/qmail/rc
/var/qmail/users

# qmail-msglog package file list.
%files msglog
%defattr(-,root,root)
%config /etc/qmail/alias/.qmail-msglog
/usr/bin/qmail/qmail-queue.msglog

# qmail-client package file list.
%files client
%defattr(-,root,root)
%config /etc/qmail/control
%ifos Linux
%config /etc/profile.d/*
%endif
%docdir /usr/doc/qmail-1.03
%docdir /usr/man
%ifos Linux
%endif
/usr/bin/qmail/config
/usr/bin/qmail/config-fast
/usr/bin/qmail/datemail
/usr/bin/qmail/dnsfq
/usr/bin/qmail/dnsip
/usr/bin/qmail/dnsptr
/usr/bin/qmail/elq
/usr/bin/qmail/hostname
/usr/bin/qmail/ipmeprint
/usr/bin/qmail/pinq
/usr/bin/qmail/predate
/usr/bin/qmail/qmail-inject
/usr/bin/qmail/qmail-qmqpc
/usr/bin/qmail/qmail-queue
/usr/bin/qmail/qmail-showctl
/usr/bin/qmail/sendmail
%dir /usr/bin/qmail
%ifos Linux
/usr/sbin/sendmail
%endif
/usr/lib/sendmail
/usr/doc/qmail-1.03
/usr/man/man*/*
/var/qmail/bin
/var/qmail/control
/var/qmail/doc
/var/qmail/man
%dir /var/qmail

==============BC1FB3CAE1227ABA7C094668==


------------------------------

From: [EMAIL PROTECTED] (Andrew Purugganan)
Subject: Anyone upgraded Mandrake successfully?
Date: 3 Mar 2001 17:05:45 GMT

I have Mandrake 6.0 but with kernel 2.2.13-22mdk. A linux rag came out 
with Mandrake 7.1 as a coverdisc CD. Has anyone successfully upgraded 
their Mandrake? Or did it involve a complete wipe n install?

In any case, I might just grab the kernel and cc compilers, possibly
XFree86 4. My .configure always complains about my c++ being broken or 
something (my own version of gcc hell)

--
jazz 
Registered linux user no. 164098  +--+--+--+ Litestep user no. 386
Doesn't it bother you, that we have to search for intelligent life
--- OUT THERE??

------------------------------

From: Luke A. Guest <[EMAIL PROTECTED]>
Crossposted-To: redhat.general
Subject: RH7, Netscape and Shockwave Flash plugin problem.
Date: Sat, 3 Mar 2001 17:50:53 +0000
Reply-To: [EMAIL PROTECTED]

Hi, 

I have been trying to get Flash to work with rh7/ns, but NS won't let me 
configure Flash.

If I type "about:plugins" I have two entries for "Shockwave Flash":

One says, "Flash file player Version 0.4.3" and says that 
"application/x-shockwave-flash" is not enabled.

The other says the same except foe the version "Shockwave Flash 5.0 r47".

Both say that the FutureSplashPlayer is enabled though.

Now, if I edit the apps by hand and put in the mimetype for Flash and then 
set it to use the plugin, it all looks like it's working except for when I 
go back into the preferences and the entry has disappeared!

I even tried added a dummy entry, then went back into the preferences and 
it was there - changed it to Flash, went back in and it was back to the 
dummy again.

WTF is going on?

Thanks,
Luke.


------------------------------


** FOR YOUR REFERENCE **

The service address, to which questions about the list itself and requests
to be added to or deleted from it should be directed, is:

    Internet: [EMAIL PROTECTED]

You can send mail to the entire list by posting to comp.os.linux.misc.

Linux may be obtained via one of these FTP sites:
    ftp.funet.fi                                pub/Linux
    tsx-11.mit.edu                              pub/linux
    sunsite.unc.edu                             pub/Linux

End of Linux-Misc Digest
******************************

Reply via email to