Re: -current as guest of VMWare2

2002-05-31 Thread Bosko Milekic


HAH! This patch was posted by iedowse in response to one of MY POSTS and
it does EXACTLY what I described in my previous Email, point (2).

PLZ DO NOT BRING MY HOPES UP BY STATING THAT THERE IS ANOTHER PATCH
WHICH DOES SOMETHING DIFFERENT WHEN IT FACT IT DOES WHAT I ALREADY KNOW
I SHOULD DO K PLZ THX. :-)

(I'm just fooling around, thanks for the pointer anyway. :-))

Cheers,
Bosko

On Fri, May 31, 2002 at 10:02:21PM +, Glenn Gombert wrote:
> Here is the patch from a previous posting that fixes the problem of
> running FreeBSD -Current as a Guest OS under VMWare Workstation 3.0:
> 
> 
> 
> Someone mentioned on a list somewhere that vmware takes forever to
> emulate the cmpxchg instruction, and that using the I386_CPU version
> of atomic_cmpset_int() helps a lot. I noticed a major vmware slowdown
> with -current sometime in September, so I tried avoiding the
> cmpxchg's and things got much faster. Below is the patch I use
> (using this outside vmware on SMP hardware is a bad idea :-).
> 
> Ian
> 
> Index: atomic.h
> ===
> RCS file: /dump/FreeBSD-CVS/src/sys/i386/include/atomic.h,v
> retrieving revision 1.21
> diff -u -r1.21 atomic.h
> --- atomic.h2001/10/08 20:58:24 1.21
> +++ atomic.h2001/10/09 18:35:25
> @@ -111,7 +111,7 @@
>   * Returns 0 on failure, non-zero on success
>   */
>  
> -#if defined(I386_CPU)
> +#if defined(I386_CPU) || 1
>  static __inline int
>  atomic_cmpset_int(volatile u_int *dst, u_int exp, u_int src)
>  {
> 
> 
> Glenn G.
> 
> 
> -- 
>   Glenn Gombert
>   [EMAIL PROTECTED]
> 
> "Never trust any operating system you don't have the source code for"
> 
> -- 
> http://fastmail.fm - Get back to work
> 

-- 
Bosko Milekic
[EMAIL PROTECTED]
[EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: -current as guest of VMWare2

2002-05-31 Thread Glenn Gombert

Here is the patch from a previous posting that fixes the problem of
running FreeBSD -Current as a Guest OS under VMWare Workstation 3.0:



Someone mentioned on a list somewhere that vmware takes forever to
emulate the cmpxchg instruction, and that using the I386_CPU version
of atomic_cmpset_int() helps a lot. I noticed a major vmware slowdown
with -current sometime in September, so I tried avoiding the
cmpxchg's and things got much faster. Below is the patch I use
(using this outside vmware on SMP hardware is a bad idea :-).

Ian

Index: atomic.h
===
RCS file: /dump/FreeBSD-CVS/src/sys/i386/include/atomic.h,v
retrieving revision 1.21
diff -u -r1.21 atomic.h
--- atomic.h2001/10/08 20:58:24 1.21
+++ atomic.h2001/10/09 18:35:25
@@ -111,7 +111,7 @@
  * Returns 0 on failure, non-zero on success
  */
 
-#if defined(I386_CPU)
+#if defined(I386_CPU) || 1
 static __inline int
 atomic_cmpset_int(volatile u_int *dst, u_int exp, u_int src)
 {


Glenn G.


-- 
  Glenn Gombert
  [EMAIL PROTECTED]

"Never trust any operating system you don't have the source code for"

-- 
http://fastmail.fm - Get back to work

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: -current as guest of VMWare2

2002-05-31 Thread Terry Lambert

Bosko Milekic wrote:
> On Fri, May 31, 2002 at 04:09:29PM +, Glenn Gombert wrote:
> >   You need to apply the patch that was posted sometime ago to -Current
> >   to run it successfully as a Guest OS under VMWare 3.x...
> 
>   I tried searching the archives and couldn't find anything with VMware
>   and a patch, just some things mentionning that VMWare has trouble with
>   locking primitives.
> 
>   What does the patch do?

Avoids using the "LCK" prefix, which VMWare emulates very, very
slowly.  The avoidance is OK, because VMWare systems are never
emulating multiprocessors.

-- Terry

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: -current as guest of VMWare2

2002-05-31 Thread Bosko Milekic


On Fri, May 31, 2002 at 04:09:29PM +, Glenn Gombert wrote:
>   You need to apply the patch that was posted sometime ago to -Current
>   to run it successfully as a Guest OS under VMWare 3.x...

  I tried searching the archives and couldn't find anything with VMware
  and a patch, just some things mentionning that VMWare has trouble with
  locking primitives.

  What does the patch do?

> Glenn G. 

-- 
Bosko Milekic
[EMAIL PROTECTED]
[EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: -current as guest of VMWare2

2002-05-31 Thread Glenn Gombert

  You need to apply the patch that was posted sometime ago to -Current
  to run it successfully as a Guest OS under VMWare 3.x...

Glenn G. 

On Fri, 31 May 2002 10:54:54 -0500, "David W. Chapman Jr."
<[EMAIL PROTECTED]> said:
> I'm running windows XP and vmware 3.1.1 with a guest os of FreeBSD 
> 4.5 which I'm going to upgrade to -current.  I couldn't find too much 
> info on this thread.  Does anyone know if vmware3 is affected by this 
> problem when using a windows host os?
> 
> -- 
> David W. Chapman Jr.
> [EMAIL PROTECTED]   Raintree Network Services, Inc.
> 
> [EMAIL PROTECTED]   FreeBSD Committer 
> 
> To Unsubscribe: send mail to [EMAIL PROTECTED]
> with "unsubscribe freebsd-current" in the body of the message
> 

-- 
  Glenn Gombert
  [EMAIL PROTECTED]

"Never trust any operating system you don't have the source code for"

-- 
http://fastmail.fm - No WWW (Wait-Wait-Wait) required

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: -current as guest of VMWare2

2002-05-31 Thread Bosko Milekic


On Fri, May 31, 2002 at 10:54:54AM -0500, David W. Chapman Jr. wrote:
> I'm running windows XP and vmware 3.1.1 with a guest os of FreeBSD 
> 4.5 which I'm going to upgrade to -current.  I couldn't find too much 
> info on this thread.  Does anyone know if vmware3 is affected by this 
> problem when using a windows host os?
> 
> -- 
> David W. Chapman Jr.
> [EMAIL PROTECTED] Raintree Network Services, Inc. 
> [EMAIL PROTECTED] FreeBSD Committer 

  As I mentionned several times now in this thread, I am running VMWare
  3.1.1 with a host OS being Windows2000 and a guest OS, -CURRENT.  I am
  doing this on my laptop so that I can "trick" -CURRENT into playing
  with my PCMCIA network card that is not supported but that works when
  used through VMWare due to VMWare emulating a LANCE type (lnc) card.

  Here are the issue I ran into with -CURRENT as guest, and what I've
  done to solve them so far:

  1) Issue: -CURRENT installation boots, kernel boots, sysinstall
  starts, but newfs-ing on partitions is EXTREMELY slow.
  Solution: Don't use the VMware 'virtual disk' thing backed with a file
  on the host OS.  Instead, create a separate partition for FreeBSD and
  install there.  Disk access is quite a bit faster.

  2) Issue: sysinstall now can newfs easily/quickly, it starts the
  install on / first, but eventually slows down to a crawl (the rate
  sinks to something ridiculous, like 0.5K/s.
  Solution: Haven't figured it out yet.  My plan is to:
 (i) Re-install -CURRENT snap in the separate partition but not
 through VMWare (i.e. do it the "normal" way).
 (ii) Boot -CURRENT normally
 (iii) Rebuild kernel without cmpxchg instruction (cpu I386_CPU, or
   whatever the name of that option was).
 (iv) Boot host OS windows2000, start VMWare, and try booting the
  installed -CURRENT with the new cmpxchg-free kernel via
  VMWare.

  I hope this at least improves the speed situation.
-- 
Bosko Milekic
[EMAIL PROTECTED]
[EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: -current as guest of VMWare2

2002-05-31 Thread David W. Chapman Jr.

I'm running windows XP and vmware 3.1.1 with a guest os of FreeBSD 
4.5 which I'm going to upgrade to -current.  I couldn't find too much 
info on this thread.  Does anyone know if vmware3 is affected by this 
problem when using a windows host os?

-- 
David W. Chapman Jr.
[EMAIL PROTECTED]   Raintree Network Services, Inc. 
[EMAIL PROTECTED]   FreeBSD Committer 

To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: -current as guest of VMWare2

2002-05-30 Thread Bosko Milekic

On Thu, May 30, 2002 at 11:46:50PM +0200, Nicolas Souchu wrote:
> Hi folks,
> 
> I'm currently trying to install -current as a guest OS of VMWare2
> running under 4.6RC.
> 
> The problem is that it works correctly except that after some
> processing, the VMWare2 engine slows down the OS incredibly. To
> get things back to a correct speed I have to suspend the VMWare
> session then restore it.
> 
> I also have a VMWare2 guest 4.6RC (running on the same 4.6RC host)
> which works like a charm.
> 
> I've compiled with the following machine file:
> 
> Any idea?
> 
> Nicholas

  Try cpu  I386_CPU and let me know how it works out!  I'm trying to do
  something similar.

  Thanks,
  Bosko.


> # $FreeBSD: src/sys/i386/conf/GENERIC,v 1.343 2002/05/22 19:00:48 obrien Exp $
> 
> machine   i386
> cpu   I486_CPU
> cpu   I586_CPU
> ident RATZ
> maxusers  0

> Nicholas Souchu - [EMAIL PROTECTED] - [EMAIL PROTECTED]

-- 
Bosko Milekic
[EMAIL PROTECTED]
[EMAIL PROTECTED]


To Unsubscribe: send mail to [EMAIL PROTECTED]
with "unsubscribe freebsd-current" in the body of the message



Re: -current as guest of VMWare2

2002-05-30 Thread Glenn Gombert

 There is a patch to fix this problem that I posted to the list
 sometime ago. I don't have it handy right now, but you can find it in
 the mailing list archive...

Glenn G. 


On Thu, 30 May 2002 23:46:50 +0200, "Nicolas Souchu" <[EMAIL PROTECTED]>
said:
> Hi folks,
> 
> I'm currently trying to install -current as a guest OS of VMWare2
> running under 4.6RC.
> 
> The problem is that it works correctly except that after some
> processing, the VMWare2 engine slows down the OS incredibly. To
> get things back to a correct speed I have to suspend the VMWare
> session then restore it.
> 
> I also have a VMWare2 guest 4.6RC (running on the same 4.6RC host)
> which works like a charm.
> 
> I've compiled with the following machine file:
> 
> Any idea?
> 
> Nicholas
> 
> 
> # $FreeBSD: src/sys/i386/conf/GENERIC,v 1.343 2002/05/22 19:00:48
> obrien Exp $
> 
> machine i386
> cpu I486_CPU
> cpu I586_CPU
> ident   RATZ
> maxusers0
> 
> #To statically compile in device wiring instead of /boot/device.hints
> hints   "RATZ.hints"#Default places to look for
> devices.
> 
> makeoptions DEBUG=-g#Build kernel with gdb(1) debug
> symbols
> 
> options INET#InterNETworking
> options INET6   #IPv6 communications protocols
> options FFS #Berkeley Fast Filesystem
> options SOFTUPDATES #Enable FFS soft updates
> support
> options UFS_DIRHASH #Improve performance on big
> directories
> options MD_ROOT #MD is a potential root device
> options NFSCLIENT   #Network Filesystem Client
> options NFSSERVER   #Network Filesystem Server
> options NFS_ROOT#NFS usable as root device,
> requires NFSCLIENT
> options MSDOSFS #MSDOS Filesystem
> options CD9660  #ISO 9660 Filesystem
> options PROCFS  #Process filesystem (requires
> PSEUDOFS)
> options PSEUDOFS#Pseudo-filesystem framework
> options COMPAT_43   #Compatible with BSD 4.3 [KEEP
> THIS!]
> options SCSI_DELAY=15000#Delay (in ms) before probing
> SCSI
> options KTRACE  #ktrace(1) support
> options SYSVSHM #SYSV-style shared memory
> options SYSVMSG #SYSV-style message queues
> options SYSVSEM #SYSV-style semaphores
> options P1003_1B#Posix P1003_1B real-time
> extensions
> options _KPOSIX_PRIORITY_SCHEDULING
> options KBD_INSTALL_CDEV# install a CDEV entry in /dev
> 
> # Debugging for use in -current
> options DDB #Enable the kernel debugger
> options INVARIANTS  #Enable calls of extra sanity
> checking
> options INVARIANT_SUPPORT   #Extra sanity checks of
> internal structures, required by INVARIANTS
> #optionsWITNESS #Enable checks to detect
> deadlocks and cycles
> #optionsWITNESS_SKIPSPIN#Don't run witness on spinlocks
> for speed
> options ALT_BREAK_TO_DEBUGGER
> 
> device  isa
> device  pci
> #optionsPCI_ENABLE_IO_MODES # Enable pci resources left off
> by a "lazy BIOS"
> 
> # Floppy drives
> device  fdc
> 
> # ATA and ATAPI devices
> device  ata
> device  atadisk # ATA disk drives
> device  atapicd # ATAPI CDROM drives
> options ATA_STATIC_ID   #Static device numbering
> 
> # atkbdc0 controls both the keyboard and the PS/2 mouse
> device  atkbdc  1   # At keyboard controller
> device  atkbd   # at keyboard
> device  psm # psm mouse
> 
> device  vga # VGA screen
> 
> # splash screen/screen saver
> device  splash
> 
> # syscons is the default console driver, resembling an SCO console
> device  sc  1
> 
> # Enable this for the pcvt (VT220 compatible) console driver
> #device vt
> #optionsXSERVER # support for X server on a vt
> console
> #optionsFAT_CURSOR  # start with block cursor
> 
> # Floating point support - do not disable.
> device  npx
> 
> # Power management support (see NOTES for more options)
> device  apm
> # Add suspend/resume support for the i8254.
> device  pmtimer
> 
> # Serial (COM) ports
> device  sio # 8250, 16[45]50 based serial ports
> 
> # Parallel port
> device  ppc
> device  ppbus   # Parallel port bus (required)
> device  lpt # Printer
> device  plip# TCP/IP over parallel
> device  ppi # Parallel port interface device
> #dev

-current as guest of VMWare2

2002-05-30 Thread Nicolas Souchu

Hi folks,

I'm currently trying to install -current as a guest OS of VMWare2
running under 4.6RC.

The problem is that it works correctly except that after some
processing, the VMWare2 engine slows down the OS incredibly. To
get things back to a correct speed I have to suspend the VMWare
session then restore it.

I also have a VMWare2 guest 4.6RC (running on the same 4.6RC host)
which works like a charm.

I've compiled with the following machine file:

Any idea?

Nicholas


# $FreeBSD: src/sys/i386/conf/GENERIC,v 1.343 2002/05/22 19:00:48 obrien Exp $

machine i386
cpu I486_CPU
cpu I586_CPU
ident   RATZ
maxusers0

#To statically compile in device wiring instead of /boot/device.hints
hints   "RATZ.hints"#Default places to look for devices.

makeoptions DEBUG=-g#Build kernel with gdb(1) debug symbols

options INET#InterNETworking
options INET6   #IPv6 communications protocols
options FFS #Berkeley Fast Filesystem
options SOFTUPDATES #Enable FFS soft updates support
options UFS_DIRHASH #Improve performance on big directories
options MD_ROOT #MD is a potential root device
options NFSCLIENT   #Network Filesystem Client
options NFSSERVER   #Network Filesystem Server
options NFS_ROOT#NFS usable as root device, requires NFSCLIENT
options MSDOSFS #MSDOS Filesystem
options CD9660  #ISO 9660 Filesystem
options PROCFS  #Process filesystem (requires PSEUDOFS)
options PSEUDOFS#Pseudo-filesystem framework
options COMPAT_43   #Compatible with BSD 4.3 [KEEP THIS!]
options SCSI_DELAY=15000#Delay (in ms) before probing SCSI
options KTRACE  #ktrace(1) support
options SYSVSHM #SYSV-style shared memory
options SYSVMSG #SYSV-style message queues
options SYSVSEM #SYSV-style semaphores
options P1003_1B#Posix P1003_1B real-time extensions
options _KPOSIX_PRIORITY_SCHEDULING
options KBD_INSTALL_CDEV# install a CDEV entry in /dev

# Debugging for use in -current
options DDB #Enable the kernel debugger
options INVARIANTS  #Enable calls of extra sanity checking
options INVARIANT_SUPPORT   #Extra sanity checks of internal structures, 
required by INVARIANTS
#optionsWITNESS #Enable checks to detect deadlocks and cycles
#optionsWITNESS_SKIPSPIN#Don't run witness on spinlocks for speed
options ALT_BREAK_TO_DEBUGGER

device  isa
device  pci
#optionsPCI_ENABLE_IO_MODES # Enable pci resources left off by a "lazy 
BIOS"

# Floppy drives
device  fdc

# ATA and ATAPI devices
device  ata
device  atadisk # ATA disk drives
device  atapicd # ATAPI CDROM drives
options ATA_STATIC_ID   #Static device numbering

# atkbdc0 controls both the keyboard and the PS/2 mouse
device  atkbdc  1   # At keyboard controller
device  atkbd   # at keyboard
device  psm # psm mouse

device  vga # VGA screen

# splash screen/screen saver
device  splash

# syscons is the default console driver, resembling an SCO console
device  sc  1

# Enable this for the pcvt (VT220 compatible) console driver
#device vt
#optionsXSERVER # support for X server on a vt console
#optionsFAT_CURSOR  # start with block cursor

# Floating point support - do not disable.
device  npx

# Power management support (see NOTES for more options)
device  apm
# Add suspend/resume support for the i8254.
device  pmtimer

# Serial (COM) ports
device  sio # 8250, 16[45]50 based serial ports

# Parallel port
device  ppc
device  ppbus   # Parallel port bus (required)
device  lpt # Printer
device  plip# TCP/IP over parallel
device  ppi # Parallel port interface device
#device vpo # Requires scbus and da

# ISA Ethernet NICs.  pccard nics included.
device  lnc # NE2100, NE32-VL Lance Ethernet cards

# Pseudo devices - the number indicates how many units to allocate.
device  random  # Entropy device
device  loop# Network loopback
device  ether   # Ethernet support
device  sl  # Kernel SLIP
device  ppp 1   # Kernel PPP
device  tun #