Skip site navigation (1)Skip section navigation (2)
Date:      Wed, 15 Dec 2004 12:07:35 -0600
From:      Eric Kjeldergaard <kjelderg@gmail.com>
To:        Nikolas Britton <freebsd@nbritton.org>
Cc:        freebsd-questions <freebsd-questions@freebsd.org>
Subject:   Re: Old Computers, -Os, Stripping, and 4-STABLE
Message-ID:  <d9175cad04121510077d0d8a2f@mail.gmail.com>
In-Reply-To: <41C032AA.4000606@nbritton.org>
References:  <41C032AA.4000606@nbritton.org>

next in thread | previous in thread | raw e-mail | index | archive | help
> 1. I'd like to know if it's (relatively) safe to use -Os for CFLAGS and
> COPTFLAGS?
 
Probably not, although it never hurts to experiment :)

> 2. I'd like to know what background stuff/daemons/etc that can be safely
> striped out, sendmail?, etc?
 
Well, I don't have your list of current processes, but if all you want
it for is a workstation and mp3 player, things like sshd and sendmail
can certainly be disabled.

> 3. Is there anyway to optimize the system for decoding / playing mp3s?
 
The mp3 player is a start.  I've had good luck on minimal systems with mpg123

> 4. Give mp3 playback a high priority and more cpu time in the system so
> it doesn't skip as much, auto reniceing?

Certainly nicing would give you more priority.  You may want to do that.

> 5. Optimize sound device resources, buffersize, dma, targetirqrate, etc
> for mp3 playback?
> 
> 6. Any other tips to improve performance?

mount / with -o noatime

> 7. Is there anything else I can safely strip out of my kernel (or add)
> that will improve performance?
> 
> here is a copy of my kernel config file:
> 
> machine        i386
> cpu        I586_CPU
> ident        STUMBLEINE_01
> maxusers    0
> 
> options        PNPBIOS
> options     INET            #InterNETworking
> options     FFS            #Berkeley Fast Filesystem
> options     FFS_ROOT        #FFS usable as root device [keep this!]
> options     SOFTUPDATES        #Enable FFS soft updates support
> options     UFS_DIRHASH        #Improve performance on big directories
> options     MFS            #Memory Filesystem
> #options     MD_ROOT            #MD is a potential root device
> #options     NFS            #Network Filesystem
> #options     NFS_ROOT        #NFS usable as root device, NFS required
> #options     MSDOSFS            #MSDOS Filesystem
> #options     CD9660            #ISO 9660 Filesystem
> #options     CD9660_ROOT        #CD-ROM usable as root, CD9660 required

> options     PROCFS            #Process filesystem
probably unnecessary 

> options     COMPAT_43        #Compatible with BSD 4.3 [KEEP THIS!]
> options     UCONSOLE        #Allow users to grab the console
> options     USERCONFIG        #boot -c editor
> options     VISUAL_USERCONFIG    #visual boot -c editor

> options     KTRACE            #ktrace(1) support
> options     SYSVSHM            #SYSV-style shared memory
> options     SYSVMSG            #SYSV-style message queues
> options     SYSVSEM            #SYSV-style semaphores
also may be unnecessary

> options     P1003_1B        #Posix P1003_1B real-time extensions
> options     _KPOSIX_PRIORITY_SCHEDULING
> options     ICMP_BANDLIM        #Rate limit bad replies
> options     KBD_INSTALL_CDEV    # install a CDEV entry in /dev
>                     # output.  Adds ~215k to driver.
> device        isa
> device        pci
> 

> # Floppy drives
> device        fdc0    at isa? port IO_FD1 irq 6 drq 2
> device        fd0    at fdc0 drive 0
> device        fd1    at fdc0 drive 1
These can be eliminated if you don't use them

> # ATA and ATAPI devices
> device        ata0    at isa? port IO_WD1 irq 14
> device        ata1    at isa? port IO_WD2 irq 15
> device        ata
> device        atadisk            # ATA disk drives
> device        atapicd            # ATAPI CDROM drives
> options     ATA_STATIC_ID        #Static device numbering
> 

> # SCSI peripherals
> device        scbus        # SCSI bus (required)
> device        da        # Direct Access (disks)
You only need these if you use scsi on your system in some way (usb
mass is what I keep them in for, but I didn't notice usb in your
config)

> 
> # atkbdc0 controls both the keyboard and the PS/2 mouse
> device        atkbdc0    at isa? port IO_KBD
> device        atkbd0    at atkbdc? irq 1 flags 0x1
> device        psm0    at atkbdc? irq 12
> 
> # Video options
> device        vga0    at isa?
> options        VESA
> options        SC_PIXEL_MODE
> 

> # splash screen/screen saver
> pseudo-device    splash
This is generally unnecesary, it's only used (as it says) for boot
splashes and screensavers.  There have been some who thought the
screensavers were a lot of overhead.

> 
> # syscons is the default console driver, resembling an SCO console
> device        sc0    at isa? flags 0x100
> 
> # Floating point support - do not disable.
> device        npx0    at nexus? port IO_NPX irq 13
> 
> # Power management support (see LINT for more options)
> device        apm0    at nexus? disable flags 0x20 # Advanced Power
> Management
> 
> # PCCARD (PCMCIA) support
> device        card
> device        pcic0    at isa? irq 0 port 0x3e0 iomem 0xd0000
> device        pcic1    at isa? irq 0 port 0x3e2 iomem 0xd4000 disable
> 
> # Serial (COM) ports
> device        sio0    at isa? port IO_COM1 flags 0x10 irq 4
> device        sio1    at isa? port IO_COM2 irq 3
> device        sio2    at isa? disable port IO_COM3 irq 5
> device        sio3    at isa? disable port IO_COM4 irq 9
Keep these only if you use your serial ports. 

> # Parallel port
> device        ppc0    at isa? irq 7
> device        ppbus        # Parallel port bus (required)
> device        lpt        # Printer
> device        plip        # TCP/IP over parallel
> device        ppi        # Parallel port interface device
if you don't use the parallel port, these can go.

> 
> # ISA/PCMCIA Ethernet NICs.
> device        miibus        # MII bus support
> device        ed0    at isa? disable port 0x280 irq 10 iomem 0xd8000
> device        ep
> device        fe0    at isa? disable port 0x300
> device        xe
This many nics?  You could load these as modules when they are in, and
keep them unloaded when they aren't.

> 
> # PRISM I IEEE 802.11b wireless NIC.
> device        awi
> # WaveLAN/IEEE 802.11 wireless NICs. Note: the WaveLAN/IEEE really
> # exists only as a PCMCIA device, so there is no ISA attachment needed
> # and resources will always be dynamically assigned by the pccard code.
> device        wi
> # Aironet 4500/4800 802.11 wireless NICs. Note: the declaration below will
> # work for PCMCIA and PCI cards, as well as ISA cards set to ISA PnP
> # mode (the factory default). If you set the switches on your ISA
> # card for a manually chosen I/O address and IRQ, you must specify
> # those parameters here.
> device        an
> 
> # The probe order of these is presently determined by i386/isa/isa_compat.c.
> #device        ie0    at isa? disable port 0x300 irq 10 iomem 0xd0000
> #device        le0    at isa? disable port 0x300 irq 5 iomem 0xd0000
> #device        lnc0    at isa? disable port 0x280 irq 10 drq 0
> #device        cs0    at isa? disable port 0x300
> device        sn0    at isa? disable port 0x300 irq 10
> 
> # Pseudo devices - the number indicates how many units to allocate.
> pseudo-device    loop        # Network loopback
> pseudo-device    ether        # Ethernet support
> #pseudo-device    sl    1    # Kernel SLIP

> pseudo-device    ppp    1    # Kernel PPP
this can go if you don't use ppp

> pseudo-device    tun        # Packet tunnel.
this can go if you don't tunnel via this machine.

> pseudo-device    pty        # Pseudo-ttys (telnet etc)
This can be removed if you don't log in to it remotely.

> pseudo-device    md        # Memory "disks"
> 
> # The `bpf' pseudo-device enables the Berkeley Packet Filter.
> # Be aware of the administrative consequences of enabling this!
> pseudo-device    bpf        #Berkeley packet filter
> 
> device        pcm        # Generic Sound Support
> device         sbc0 at isa? port 0x220 irq 10 drq 1
>


Those are the ones that I see at first.  A close examination of your
own ps fauxw output would tell you what's running and you could try
killing the ones that seem unnecessary.  Good luck.

-- 
If I write a signature, my emails will appear more personalised.



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?d9175cad04121510077d0d8a2f>