BSD is low-performance than XP! HOWTO Improve ?

Hi,

Any suggestion to improve the performance in BSD ? I found that it's exactly much lower than XP, which could be switched.

'Coz Im a newer, so it's better to show me some ways to learn this.;)
 
It's Intel P4 with 1 G memory.
For an example, Firefox runs slowly and it's the same as to refresh the pages.
 
Ignore Firefox.

I still feel the system performance is not good as my expect. Do you have some advices ?
 
If would help if you provided more details as well, like what version of FreeBSD you're running, what you're doing when you see the performance drop, etc.
 
And don't forget to tell us what hardware you are using. If you don't have 2D acceleration with Xorg, things can feel very slow.

Adam
 
What is 'the system performance'? Video? Disk? Network? Boot time? Making toast?
 
Define performance and/or give examples.
Firefox is quite slow as vermaden said, and as he recommended you can try Opera.

The machine I use as my desktop is a PIV too, but it has a 384MB memory! and Opera starts and operates very fast. I haven't tried to time it against the Windows version, but it seems to have a very similar performance.
All the applications I use are lightweight, run fast and have relatively low memory footprints. The system itself takes 30-35 seconds to start (delays/countdowns included) from bootup to login, compared to 45 seconds to +1 minute for Windows 2000. FreeBSD is faster and more responsive in every way compared even to Windows 95 or 98SE.
The only thing that is slower is graphics redrawing. That's because I had to disable all hardware acceleration due to lockups, but this is mostly related to Xorg, not FreeBSD.
 
Sorry, actually I'm not clear what exactly to make the system slow. So I can't tell what it is. I just feel that the web page loading much slower in Firefox, even in Opera it's better, but it's still slow, comparing the feeling in WinXP.

I don't know what and why made this.
My status now is FreeBSD 8.0 standard installed, no kernel and anything else customization (Not study yet), and I'm installing the ports with configuration following the handbook.
The exact what I wanna know is how to speed up on surfing the web as it could be in WinXP.
 
Post the contents of following files;

Code:
/etc/rc.conf
/etc/X11/xorg.conf

And the output of following commands;

Code:
dmesg
xdpyinfo

And tell us what desktop environment / window manager are you running, plus the exact brand / model of your graphics adapter.

I'm running FreeBSD 8 on Toshiba Satellite Pro M10 (P4M 1.6GHz / 2 GB RAM / nVidia GF4GO 32MB, slow ATA-100 5400RPM 80GB HDD) and the system behaves way better than Windows XP. The initial state after boot into Xorg may feel a bit slower on response than XP, but when you load it with some real work...boy does BSD bliss over XP there.
 
I found when I used to use Gnome, the whole thing felt really sluggish. The Windows XP shell is much lighter and faster in comparison, so perhaps use something like Xfce4 or JoeWM.
 
Thanks a lot, Zare.;)

The window manager is Xfce4 and FreeBSD 8.0 runs on hp compaq (Pentium(R) 4 CPU 2.60GHz / 1 G Memory / Intel 82865G (865G GMCH) SVGA controller). Xorg and Xfce4 are just initialized. I'm learning how to make the hardwares work really.
 
For /etc/rc.conf

Code:
# -- sysinstall generated deltas -- # Sat Mar 20 08:48:05 2010
# Created: Sat Mar 20 08:48:05 2010
# Enable network daemons for user convenience.
# Please make all changes to this file, not to /etc/defaults/rc.conf.
# This file now contains just the overrides from /etc/defaults/rc.conf.
hostname="jerry.xu.net"
ifconfig_bge0="DHCP"
inetd_enable="NO"
keymap="us.iso"
nfs_client_enable="YES"
sshd_enable="YES"
hald_enable="YES"
dbus_enable="YES"

fusefs_enable="YES"
 
For /etc/X11/xorg.conf

Code:
Section "ServerLayout"
        Identifier     "X.org Configured"
        Screen      0  "Screen0" 0 0
        InputDevice    "Mouse0" "CorePointer"
        InputDevice    "Keyboard0" "CoreKeyboard"
EndSection

Section "Files"
        ModulePath   "/usr/local/lib/xorg/modules"
        FontPath     "/usr/local/lib/X11/fonts/misc/"
        FontPath     "/usr/local/lib/X11/fonts/TTF/"
        FontPath     "/usr/local/lib/X11/fonts/OTF"
        FontPath     "/usr/local/lib/X11/fonts/Type1/"
        FontPath     "/usr/local/lib/X11/fonts/100dpi/"
        FontPath     "/usr/local/lib/X11/fonts/75dpi/"
        FontPath     "/usr/local/lib/X11/fonts/URW/"
        FontPath     "/usr/local/lib/X11/fonts/TrueType/"
EndSection

Section "Module"
        Load  "dbe"
        Load  "dri"
        Load  "dri2"
        Load  "extmod"
        Load  "glx"
        Load  "record"
        Load  "freetype"
EndSection

Section "InputDevice"
        Identifier  "Keyboard0"
        Driver      "kbd"
EndSection

Section "InputDevice"
        Identifier  "Mouse0"
        Driver      "mouse"
        Option      "Protocol" "auto"
        Option      "Device" "/dev/sysmouse"
        Option      "ZAxisMapping" "4 5 6 7"
EndSection

Section "Monitor"
        Identifier   "Monitor0"
        VendorName   "Monitor Vendor"
        ModelName    "Monitor Model"
        Modeline     "1680x1050" 119.00 1680 1728 1760 1840 1050 1053 1059 1080
        Option       "DPMS"
EndSection

Section "Device"
        ### Available Driver options are:-
        ### Values: <i>: integer, <f>: float, <bool>: "True"/"False",
        ### <string>: "String", <freq>: "<f> Hz/kHz/MHz"
        ### [arg]: arg optional
        #Option     "NoAccel"                   # [<bool>]
        #Option     "SWcursor"                  # [<bool>]
        #Option     "ColorKey"                  # <i>
        #Option     "CacheLines"                # <i>
        #Option     "Dac6Bit"                   # [<bool>]
        #Option     "DRI"                       # [<bool>]
        #Option     "NoDDC"                     # [<bool>]
        #Option     "ShowCache"                 # [<bool>]
        #Option     "XvMCSurfaces"              # <i>
        #Option     "PageFlip"                  # [<bool>]
        Identifier  "Card0"
        Driver      "intel"
        VendorName  "Intel Corporation"
        BoardName   "82865G Integrated Graphics Controller"
        BusID       "PCI:0:2:0"
EndSection

Section "Screen"
        Identifier "Screen0"
        Device     "Card0"
        Monitor    "Monitor0"
        DefaultDepth 24
        SubSection "Display"
                Viewport   0 0
                Depth     1
        EndSubSection
        SubSection "Display"
                Viewport   0 0
                Depth     4
        EndSubSection
        SubSection "Display"
                Viewport   0 0
                Depth     8
        EndSubSection
        SubSection "Display"
                Viewport   0 0
                Depth     15
        EndSubSection
        SubSection "Display"
                Viewport   0 0
                Depth     16
        EndSubSection
        SubSection "Display"
                Viewport   0 0
                Depth     24
                Modes     "1680x1050"
        EndSubSection
EndSection
 
Code:
$ dmesg 
Copyright (c) 1992-2009 The FreeBSD Project.
Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994
	The Regents of the University of California. All rights reserved.
FreeBSD is a registered trademark of The FreeBSD Foundation.
FreeBSD 8.0-RELEASE #0: Sat Nov 21 15:48:17 UTC 2009
    [email]root@almeida.cse.buffalo.edu[/email]:/usr/obj/usr/src/sys/GENERIC
Timecounter "i8254" frequency 1193182 Hz quality 0
CPU: Intel(R) Pentium(R) 4 CPU 2.60GHz (2593.51-MHz 686-class CPU)
  Origin = "GenuineIntel"  Id = 0xf29  Stepping = 9
  Features=0xbfebfbff<FPU,VME,DE,PSE,TSC,MSR,PAE,MCE,CX8,APIC,SEP,MTRR,PGE,MCA,CMOV,PAT,PSE36,CLFLUSH,DTS,ACPI,MMX,FXSR,SSE,SSE2,SS,HTT,TM,PBE>
  Features2=0x4400<CNXT-ID,xTPR>
real memory  = 1074266112 (1024 MB)
avail memory = 1028091904 (980 MB)
ACPI APIC Table: <COMPAQ SPRINGD >
FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs
FreeBSD/SMP: 1 package(s) x 1 core(s) x 2 HTT threads
 cpu0 (BSP): APIC ID:  0
 cpu1 (AP/HT): APIC ID:  1
ioapic0: Changing APIC ID to 1
ioapic0 <Version 2.0> irqs 0-23 on motherboard
kbd1 at kbdmux0
acpi0: <COMPAQ CPQ0064> on motherboard
acpi0: [ITHREAD]
acpi0: Power Button (fixed)
acpi0: reservation of 0, a0000 (3) failed
acpi0: reservation of 100000, 3f700000 (3) failed
Timecounter "ACPI-fast" frequency 3579545 Hz quality 1000
acpi_timer0: <24-bit timer at 3.579545MHz> port 0xf808-0xf80b on acpi0
pcib0: <ACPI Host-PCI bridge> port 0xcf8-0xcff on acpi0
pci0: <ACPI PCI bus> on pcib0
vgapci0: <VGA-compatible display> port 0x14e0-0x14e7 mem 0xf0000000-0xf7ffffff,0xfc400000-0xfc47ffff irq 16 at device 2.0 on pci0
agp0: <Intel 82865G (865G GMCH) SVGA controller> on vgapci0
agp0: detected 8060k stolen memory
agp0: aperture size is 128M
uhci0: <Intel 82801EB (ICH5) USB controller USB-A> port 0x1440-0x145f irq 16 at device 29.0 on pci0
uhci0: [ITHREAD]
uhci0: LegSup = 0x0020
usbus0: <Intel 82801EB (ICH5) USB controller USB-A> on uhci0
uhci1: <Intel 82801EB (ICH5) USB controller USB-B> port 0x1460-0x147f irq 19 at device 29.1 on pci0
uhci1: [ITHREAD]
uhci1: LegSup = 0x0020
usbus1: <Intel 82801EB (ICH5) USB controller USB-B> on uhci1
uhci2: <Intel 82801EB (ICH5) USB controller USB-C> port 0x1480-0x149f irq 18 at device 29.2 on pci0
uhci2: [ITHREAD]
uhci2: LegSup = 0x0020
usbus2: <Intel 82801EB (ICH5) USB controller USB-C> on uhci2
ehci0: <Intel 82801EB/R (ICH5) USB 2.0 controller> mem 0xfc480000-0xfc4803ff irq 23 at device 29.7 on pci0
ehci0: [ITHREAD]
usbus3: EHCI version 1.0
usbus3: <Intel 82801EB/R (ICH5) USB 2.0 controller> on ehci0
pcib1: <ACPI PCI-PCI bridge> at device 30.0 on pci0
pci5: <ACPI PCI bus> on pcib1
bge0: <Broadcom NetXtreme Gigabit Ethernet Controller, ASIC rev. 0x3003> mem 0xfc500000-0xfc50ffff irq 20 at device 2.0 on pci5
miibus0: <MII bus> on bge0
brgphy0: <BCM5705 10/100/1000baseTX PHY> PHY 1 on miibus0
brgphy0:  10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, 1000baseT, 1000baseT-FDX, auto
bge0: Ethernet address: 00:0f:20:74:c3:51
bge0: [ITHREAD]
isab0: <PCI-ISA bridge> at device 31.0 on pci0
isa0: <ISA bus> on isab0
atapci0: <Intel ICH5 UDMA100 controller> port 0x1f0-0x1f7,0x3f6,0x170-0x177,0x376,0x14c0-0x14cf irq 18 at device 31.1 on pci0
ata0: <ATA channel 0> on atapci0
ata0: [ITHREAD]
ata1: <ATA channel 1> on atapci0
ata1: [ITHREAD]
atapci1: <Intel ICH5 SATA150 controller> port 0x14f8-0x14ff,0x1810-0x1813,0x1800-0x1807,0x1814-0x1817,0x14d0-0x14df irq 18 at device 31.2 on pci0
atapci1: [ITHREAD]
ata2: <ATA channel 0> on atapci1
ata2: [ITHREAD]
ata3: <ATA channel 1> on atapci1
ata3: [ITHREAD]
pci0: <multimedia, audio> at device 31.5 (no driver attached)
acpi_button0: <Power Button> on acpi0
atrtc0: <AT realtime clock> port 0x70-0x71 irq 8 on acpi0
atkbdc0: <Keyboard controller (i8042)> port 0x60,0x64 irq 1 on acpi0
atkbd0: <AT Keyboard> irq 1 on atkbdc0
kbd0 at atkbd0
atkbd0: [GIANT-LOCKED]
atkbd0: [ITHREAD]
ppc0: <Parallel port> port 0x378-0x37f,0x778-0x77d irq 7 drq 3 on acpi0
ppc0: SMC-like chipset (ECP/EPP/PS2/NIBBLE) in COMPATIBLE mode
ppc0: FIFO with 16/16/13 bytes threshold
ppc0: [ITHREAD]
ppbus0: <Parallel port bus> on ppc0
plip0: <PLIP network interface> on ppbus0
plip0: [ITHREAD]
lpt0: <Printer> on ppbus0
lpt0: [ITHREAD]
lpt0: Interrupt-driven port
ppi0: <Parallel I/O> on ppbus0
uart0: <16550 or compatible> port 0x3f8-0x3ff irq 4 flags 0x10 on acpi0
uart0: [FILTER]
fdc0: <floppy drive controller> port 0x3f0-0x3f5,0x3f7 irq 6 drq 2 on acpi0
fdc0: [FILTER]
fd0: <1440-KB 3.5" drive> on fdc0 drive 0
cpu0: <ACPI CPU> on acpi0
p4tcc0: <CPU Frequency Thermal Control> on cpu0
cpu1: <ACPI CPU> on acpi0
p4tcc1: <CPU Frequency Thermal Control> on cpu1
pmtimer0 on isa0
sc0: <System console> at flags 0x100 on isa0
sc0: VGA <16 virtual consoles, flags=0x300>
vga0: <Generic ISA VGA> at port 0x3c0-0x3df iomem 0xa0000-0xbffff on isa0
uart1: <16550 or compatible> at port 0x2f8-0x2ff irq 3 on isa0
uart1: [FILTER]
Timecounters tick every 1.000 msec
usbus0: 12Mbps Full Speed USB v1.0
usbus1: 12Mbps Full Speed USB v1.0
usbus2: 12Mbps Full Speed USB v1.0
usbus3: 480Mbps High Speed USB v2.0
ad0: 76319MB <WDC WD800JB-00JJC0 05.01C05> at ata0-master UDMA100
ugen0.1: <Intel> at usbus0
uhub0: <Intel UHCI root HUB, class 9/0, rev 1.00/1.00, addr 1> on usbus0
ugen1.1: <Intel> at usbus1
uhub1: <Intel UHCI root HUB, class 9/0, rev 1.00/1.00, addr 1> on usbus1
ugen2.1: <Intel> at usbus2
uhub2: <Intel UHCI root HUB, class 9/0, rev 1.00/1.00, addr 1> on usbus2
ugen3.1: <Intel> at usbus3
uhub3: <Intel EHCI root HUB, class 9/0, rev 2.00/1.00, addr 1> on usbus3
acd0: DVDROM <NEC DV-5700A/3.07> at ata1-master UDMA33
SMP: AP CPU #1 Launched!
uhub0: 2 ports with 2 removable, self powered
uhub1: 2 ports with 2 removable, self powered
uhub2: 2 ports with 2 removable, self powered
Root mount waiting for: usbus3
Root mount waiting for: usbus3
Root mount waiting for: usbus3
uhub3: 8 ports with 8 removable, self powered
Trying to mount root from ufs:/dev/ad0s3a
ugen1.2: <MLK> at usbus1
ukbd0: <EP1 Interrupt> on usbus1
kbd2 at ukbd0
ums0: <EP2 Interrupt> on usbus1
ums0: 5 buttons and [XYZ] coordinates ID=1
ugen2.2: <SIGMACH1P> at usbus2
ums1: <SIGMACH1P U+P Mouse, class 0/0, rev 1.10/1.10, addr 2> on usbus2
ums1: 3 buttons and [XYZ] coordinates ID=0
fuse4bsd: version 0.3.9-pre1, FUSE ABI 7.8
bge0: link state changed to UP
drm0: <Intel i865G GMCH> on vgapci0
vgapci0: child drm0 requested pci_enable_busmaster
info: [drm] AGP at 0xf0000000 128MB
info: [drm] Initialized i915 1.6.0 20080730
drm0: [ITHREAD]
 
Code:
$ xdpyinfo
name of display:    :0.0
version number:    11.0
vendor string:    The X.Org Foundation
vendor release number:    10601000
X.Org version: 1.6.1
maximum request size:  16777212 bytes
motion buffer size:  256
bitmap unit, bit order, padding:    32, LSBFirst, 32
image byte order:    LSBFirst
number of supported pixmap formats:    7
supported pixmap formats:
    depth 1, bits_per_pixel 1, scanline_pad 32
    depth 4, bits_per_pixel 8, scanline_pad 32
    depth 8, bits_per_pixel 8, scanline_pad 32
    depth 15, bits_per_pixel 16, scanline_pad 32
    depth 16, bits_per_pixel 16, scanline_pad 32
    depth 24, bits_per_pixel 32, scanline_pad 32
    depth 32, bits_per_pixel 32, scanline_pad 32
keycode range:    minimum 8, maximum 255
focus:  window 0x1c00005, revert to Parent
number of extensions:    27
    BIG-REQUESTS
    Composite
    DAMAGE
    DOUBLE-BUFFER
    DPMS
    DRI2
    GLX
    Generic Event Extension
    MIT-SCREEN-SAVER
    MIT-SHM
    RANDR
    RECORD
    RENDER
    SGI-GLX
    SHAPE
    SYNC
    X-Resource
    XC-MISC
    XFIXES
    XFree86-DGA
    XFree86-DRI
    XFree86-VidModeExtension
    XINERAMA
    XInputExtension
    XKEYBOARD
    XTEST
    XVideo
default screen number:    0
number of screens:    1

screen #0:
  print screen:    no
  dimensions:    1680x1050 pixels (459x296 millimeters)
  resolution:    93x90 dots per inch
  depths (7):    24, 1, 4, 8, 15, 16, 32
  root window id:    0x114
  depth of root window:    24 planes
  number of colormaps:    minimum 1, maximum 1
  default colormap:    0x20
  default number of colormap cells:    256
  preallocated pixels:    black 0, white 16777215
  options:    backing-store NO, save-unders NO
  largest cursor:    64x64
  current input event mask:    0x7ac03c
    ButtonPressMask          ButtonReleaseMask        EnterWindowMask          
    LeaveWindowMask          KeymapStateMask          ExposureMask             
    StructureNotifyMask      SubstructureNotifyMask   SubstructureRedirectMask 
    FocusChangeMask          PropertyChangeMask       
  number of visuals:    64
  default visual id:  0x21
  visual:
    visual id:    0x21
    class:    TrueColor
    depth:    24 planes
    available colormap entries:    256 per subfield
    red, green, blue masks:    0xff0000, 0xff00, 0xff
    significant bits in color specification:    8 bits
......
 
Hi fronclynne,

Could you explain more on your cmd
# nice -n 20 make buildworld


fronclynne said:
Windows is hella fast. I just ran # nice -n 20 make buildworld on Windows and it gave me a new command prompt in less than one second. That is fast.
 
No slowness here

FreeJX said:
Hi fronclynne,

Could you explain more on your cmd
# nice -n 20 make buildworld

He was obviously being facetious. Although if you're comfortable tweaking your own kernel and rebuilding your system with the 'pentium4' CFLAG you'd get more speed. Question for you: how is the speed at the console without X running? Does it run fine then slow down? What do systat and vmstat report?

I experienced firefox3.6 running about as fast as opera. Of course, that's custom compiled not from pkg_add.
 
rossiya said:
He was obviously being facetious. Although if you're comfortable tweaking your own kernel and rebuilding your system with the 'pentium4' CFLAG you'd get more speed.

prove it. I doubt it will give any measurable performance boost on modern hardware
 
FreeJX, disable hald and dbus, and add

Code:
Option    AllowEmptyInput   "Off"

in ServerLayout section of xorg.conf. HAL and D-BUS really make my laptop sluggish, they seem to query hardware way too often and eat 10% of CPU easily. By the way, you don't really need them for X if that's desktop computer.

Also, while your XFCE is up, switch to another virtual console (Alt+F2, for instance), login, run top and post the output.

Otherwise, your config seems OK.
 
Back
Top