Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 22 Jan 2008 15:10:10 +0400
From:      Gaspar Chilingarov <nm@web.am>
To:        Boris Samorodov <bsam@ipt.ru>
Cc:        freebsd-emulation@freebsd.org, bug-followup@FreeBSD.org
Subject:   Re: ports/119880: emulators/linux_base-f7 - [linux] OpenOffice 2.x fails after portupgrade with "error writing file"
Message-ID:  <4795CF12.5010003@web.am>
In-Reply-To: <61386061@bb.ipt.ru>
References:  <61386061@bb.ipt.ru>

next in thread | previous in thread | raw e-mail | index | archive | help
Boris Samorodov wrote:
> The port itself doesn't install LINUXBASE/tmp (it is removed before
> install). Take a look at the Makefile:
> -----
> ...
> REMOVE_DIRS= boot dev home initrd root tmp var/log var/run var/tmp
> ...
> -----
> 
> Seems that you have a stale directory. Please check it up.
> 
> WBR

I got the source of the problem.

If you run OpenOffice using root account, it creates /compat/linux/tmp 
with illegal permissions.

Shouldn't linuxolator report to linux applications that /tmp exists, 
even if we have no /compat/linux/tmp, but have /tmp ? This is a trace of 
opeoffice calls

  42087 soffice.bin CALL  close(0xc)
  42087 soffice.bin RET   close 0
  42087 soffice.bin CALL  linux_mkdir(0xffffc5fc,0x1ff)
  42087 soffice.bin NAMI  "/compat/linux"
  42087 soffice.bin NAMI  "/compat/linux/tmp"
  42087 soffice.bin RET   linux_mkdir 0
  42087 soffice.bin CALL  umask(0x3f)
  42087 soffice.bin RET   umask 18/0x12
  42087 soffice.bin CALL  linux_open(0xffffc4e4,0x18800,0xffffc4e8)
  42087 soffice.bin NAMI  "/compat/linux/tmp"
  42087 soffice.bin NAMI  "/compat/linux"
  42087 soffice.bin NAMI  "/compat/linux/tmp"
  42087 soffice.bin RET   linux_open 12/0xc
  42087 soffice.bin CALL  linux_fstat64(0xc,0xffffc468,0x2935fff4)
  42087 soffice.bin RET   linux_fstat64 0
  42087 soffice.bin CALL  linux_fcntl64(0xc,0x2,0x1)
  42087 soffice.bin RET   linux_fcntl64 0
  42087 soffice.bin CALL  umask(0x12)
  42087 soffice.bin RET   umask 63/0x3f
  42087 soffice.bin CALL  close(0xc)
  42087 soffice.bin RET   close 0
  42087 soffice.bin CALL  gettimeofday(0xffffd4ec,0)
  42087 soffice.bin RET   gettimeofday 0
  42087 soffice.bin CALL  linux_mkdir(0xffffc4ec,0x1ff)
  42087 soffice.bin NAMI  "/compat/linux/tmp"
  42087 soffice.bin NAMI  "/compat/linux/tmp/sv248.tmp"
  42087 soffice.bin RET   linux_mkdir 0
  42087 soffice.bin CALL  linux_mkdir(0xffffbd30,0x1ff)

As you can see, mkdir does not check, that fallback directory exists, 
but creates one under /compat/linux .... is it right?


I'm off the -emulation list, so please cc me.

Kernel info:
FreeBSD aldan.web.am 8.0-CURRENT FreeBSD 8.0-CURRENT #1: Thu Jan 10 
22:39:43 AMT 2008 
root@aldan.web.am:/mnt/ufsflash/src/obj/usr/src1/sys/nm  amd64

compat.linux.osrelease: 2.4.20


/Gaspar




-- 
Gaspar Chilingarov

System Administrator,
Network security consulting

t +37493 419763 (mob)
i 63174784
e nm@web.am
w http://gasparchilingarov.com/



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