public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* New installation of Cygwin64: xinit.sh exit code 3
@ 2023-10-21  9:57 Fergus Daly
  2023-10-21 10:52 ` Fergus Daly
  0 siblings, 1 reply; 8+ messages in thread
From: Fergus Daly @ 2023-10-21  9:57 UTC (permalink / raw)
  To: 'cygwin@cygwin.com'; +Cc: Fergus Daly

I made a new installation of Cygwin 64 on a new USB stick, including the package xinit.
(I use setup -P followed by a longish but far from complete list of required packages ..,..,xinit,..,..)
At this first use of setup I got a single error message:
      Package: _/xinit xinit.sh exit code 3
At 2nd and all subsequent uses of setup (i.e. as update) I get the slightly altered error message: 
      Package: _/Unknown package xinit.sh exit code 3
In practice, any usage of xinit (e.g. to launch xterm) seems to work perfectly well, but the 
repeated error message at any update transaction (including when empty) is disconcerting.
I have not tried an explicit command "bash (or dash) /etc/postinstall/xinit.sh" as - even if this
worked - I would prefer to canvass opinion on this minor glitch.
All the same - the glitch is recent, despite being minor .. ..

^ permalink raw reply	[flat|nested] 8+ messages in thread

* RE: New installation of Cygwin64: xinit.sh exit code 3
  2023-10-21  9:57 New installation of Cygwin64: xinit.sh exit code 3 Fergus Daly
@ 2023-10-21 10:52 ` Fergus Daly
  2023-10-21 16:21   ` Brian Inglis
  2023-10-22  4:46   ` Fergus Daly
  0 siblings, 2 replies; 8+ messages in thread
From: Fergus Daly @ 2023-10-21 10:52 UTC (permalink / raw)
  To: 'cygwin@cygwin.com'; +Cc: Fergus Daly

Should have added: the file /var/log/setup.log shows no detail beyond
2023/10/21 09:29:46 running: G:\console64\bin\bash.exe --norc --noprofile "/etc/postinstall/xinit.sh"
2023/10/21 09:29:49 abnormal exit: exit code=3

-----Original Message-----

I made a new installation of Cygwin 64 on a new USB stick, including the package xinit.
(I use setup -P followed by a longish but far from complete list of required packages ..,..,xinit,..,..) At this first use of setup I got a single error message:
      Package: _/xinit xinit.sh exit code 3 At 2nd and all subsequent uses of setup (i.e. as update) I get the slightly altered error message: 
      Package: _/Unknown package xinit.sh exit code 3 In practice, any usage of xinit (e.g. to launch xterm) seems to work perfectly well, but the repeated error message at any update transaction (including when empty) is disconcerting.
I have not tried an explicit command "bash (or dash) /etc/postinstall/xinit.sh" as - even if this worked - I would prefer to canvass opinion on this minor glitch.
All the same - the glitch is recent, despite being minor .. ..


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: New installation of Cygwin64: xinit.sh exit code 3
  2023-10-21 10:52 ` Fergus Daly
@ 2023-10-21 16:21   ` Brian Inglis
  2023-10-22  4:46   ` Fergus Daly
  1 sibling, 0 replies; 8+ messages in thread
From: Brian Inglis @ 2023-10-21 16:21 UTC (permalink / raw)
  To: cygwin

On 2023-10-21 04:52, Fergus Daly via Cygwin wrote:
> Should have added: the file /var/log/setup.log shows no detail beyond
> 2023/10/21 09:29:46 running: G:\console64\bin\bash.exe --norc --noprofile "/etc/postinstall/xinit.sh"
> 2023/10/21 09:29:49 abnormal exit: exit code=3
> 
> -----Original Message-----
> 
> I made a new installation of Cygwin 64 on a new USB stick, including the package xinit.
> (I use setup -P followed by a longish but far from complete list of required packages ..,..,xinit,..,..) At this first use of setup I got a single error message:
>        Package: _/xinit xinit.sh exit code 3 At 2nd and all subsequent uses of setup (i.e. as update) I get the slightly altered error message:
>        Package: _/Unknown package xinit.sh exit code 3 In practice, any usage of xinit (e.g. to launch xterm) seems to work perfectly well, but the repeated error message at any update transaction (including when empty) is disconcerting.
> I have not tried an explicit command "bash (or dash) /etc/postinstall/xinit.sh" as - even if this worked - I would prefer to canvass opinion on this minor glitch.
> All the same - the glitch is recent, despite being minor .. ..

What filesystem is the drive formatted as: NTFS, ExFAT, FAT32, or other?

Try rerunning the xinit postinstall script as follows and report the failing 
command(s) and error messages:

	$ CYGWINFORALL=-A /bin/sh -vx /etc/postinstall/xinit.sh

-- 
Take care. Thanks, Brian Inglis              Calgary, Alberta, Canada

La perfection est atteinte                   Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter  not when there is no more to add
mais lorsqu'il n'y a plus rien à retirer     but when there is no more to cut
                                 -- Antoine de Saint-Exupéry

^ permalink raw reply	[flat|nested] 8+ messages in thread

* RE: New installation of Cygwin64: xinit.sh exit code 3
  2023-10-21 10:52 ` Fergus Daly
  2023-10-21 16:21   ` Brian Inglis
@ 2023-10-22  4:46   ` Fergus Daly
  2023-10-22 13:47     ` Brian Inglis
  2023-10-23 12:05     ` Fergus Daly
  1 sibling, 2 replies; 8+ messages in thread
From: Fergus Daly @ 2023-10-22  4:46 UTC (permalink / raw)
  To: 'cygwin@cygwin.com'; +Cc: Fergus Daly

>> Should have added: the file /var/log/setup.log shows no detail beyond
>> 2023/10/21 09:29:46 running: G:\console64\bin\bash.exe --norc --noprofile "/etc/postinstall/xinit.sh"
>> 2023/10/21 09:29:49 abnormal exit: exit code=3
>> 
>> -----Original Message-----
>> 
>> I made a new installation of Cygwin 64 on a new USB stick, including the package xinit.
>> (I use setup -P followed by a longish but far from complete list of required packages ..,..,xinit,..,..)
>> At this first use of setup I got a single error message:
>>        Package: _/xinit xinit.sh exit code 3
>> At 2nd and all subsequent uses of setup (i.e. as update) I get the slightly altered error message:
>>        Package: _/Unknown package xinit.sh exit code 3
>> In practice, any usage of xinit (e.g. to launch xterm) seems to work perfectly well, but the repeated
>> error message at any update transaction (including when empty) is disconcerting.
>> I have not tried an explicit command "bash (or dash) /etc/postinstall/xinit.sh" as - even if this worked -
>> I would prefer to canvass opinion on this minor glitch.
>> All the same - the glitch is recent, despite being minor .. ..

> What filesystem is the drive formatted as: NTFS, ExFAT, FAT32, or other?
> Try rerunning the xinit postinstall script as follows and report the failing 
> command(s) and error messages:
> 	$ CYGWINFORALL=-A /bin/sh -vx /etc/postinstall/xinit.sh

Thank you!
1. The identical error msg occurs on all of NTFS, FAT32, exFAT file systems.
2. The output from your test command is identical on all file systems,
3. The failing commands are the two separate "case .. mkdir .. mkshortcut" sequences that occur
at the end of the xinit.sh script, with consequent error notification as follows:

case $(uname -s) in *-WOW*) wow64=" (32-bit)" ;; esac
+ case $(uname -s) in
++ uname -s
/usr/bin/mkdir -p "$(/usr/bin/cygpath $CYGWINFORALL -P)/Cygwin-X${wow64}"
++ /usr/bin/cygpath -A -P
+ /usr/bin/mkdir -p '/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/Cygwin-X'
/usr/bin/mkshortcut $CYGWINFORALL -P -w / -i /usr/bin/xwin-xdg-menu.exe -n "Cygwin-X${wow64}/XWin Server" -a "--quote /usr/bin/bash.exe
 -l -c \"cd; exec /usr/bin/startxwin\"" /usr/bin/run.exe
+ /usr/bin/mkshortcut -A -P -w / -i /usr/bin/xwin-xdg-menu.exe -n 'Cygwin-X/XWin Server' -a '--quote /usr/bin/bash.exe
 -l -c "cd; exec /usr/bin/startxwin"' /usr/bin/run.exe
mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/Cygwin-X/XWin Server.lnk" failed; 
does the target directory exist?

case $(uname -s) in *-WOW*) wow64=" (32-bit)" ;; esac
+ case $(uname -s) in
++ uname -s
/usr/bin/mkdir -p "$(/usr/bin/cygpath $CYGWINFORALL -P)/Cygwin-X${wow64}"
++ /usr/bin/cygpath -A -P
+ /usr/bin/mkdir -p '/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/Cygwin-X'
/usr/bin/mkshortcut $CYGWINFORALL -P -w / -i /usr/bin/XWin.exe -n "Cygwin-X${wow64}/User script" -a "--quote /usr/bin/bash.exe
 -l -c \"cd; XSESSION_ICON= exec /usr/bin/startx /etc/X11/xinit/Xsession xinit-compat\"" /usr/bin/run.exe
+ /usr/bin/mkshortcut -A -P -w / -i /usr/bin/XWin.exe -n 'Cygwin-X/User script' -a '--quote /usr/bin/bash.exe
 -l -c "cd; XSESSION_ICON= exec /usr/bin/startx /etc/X11/xinit/Xsession xinit-compat"' /usr/bin/run.exe
mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/Cygwin-X/User script.lnk" failed;
 does the target directory exist?

When I used Explorer to visit C:\ProgramData\Microsoft\Windows\Start Menu\Cygwin-X I was told:
"You don't currently have permission to access this folder"
and clicking on Continue to get access I was told:
"You have been denied permission to access this folder"
There was then offered an option to edit Permissions which I didn't feel like pursuing.

(I am the Administrator on my own standalone Windows machine. The denial of access to Cygwin-X feels odd.
PS I also have Cygwin32 installed and running. I _am_ permitted access to the equivalent folder Cygwin-X (32-bit).)


^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: New installation of Cygwin64: xinit.sh exit code 3
  2023-10-22  4:46   ` Fergus Daly
@ 2023-10-22 13:47     ` Brian Inglis
  2023-10-23 12:05     ` Fergus Daly
  1 sibling, 0 replies; 8+ messages in thread
From: Brian Inglis @ 2023-10-22 13:47 UTC (permalink / raw)
  To: cygwin

On 2023-10-21 22:46, Fergus Daly via Cygwin wrote:
>>> Should have added: the file /var/log/setup.log shows no detail beyond
>>> 2023/10/21 09:29:46 running: G:\console64\bin\bash.exe --norc --noprofile "/etc/postinstall/xinit.sh"
>>> 2023/10/21 09:29:49 abnormal exit: exit code=3
>>>
>>> -----Original Message-----
>>>
>>> I made a new installation of Cygwin 64 on a new USB stick, including the package xinit.
>>> (I use setup -P followed by a longish but far from complete list of required packages ..,..,xinit,..,..)
>>> At this first use of setup I got a single error message:
>>>         Package: _/xinit xinit.sh exit code 3
>>> At 2nd and all subsequent uses of setup (i.e. as update) I get the slightly altered error message:
>>>         Package: _/Unknown package xinit.sh exit code 3
>>> In practice, any usage of xinit (e.g. to launch xterm) seems to work perfectly well, but the repeated
>>> error message at any update transaction (including when empty) is disconcerting.
>>> I have not tried an explicit command "bash (or dash) /etc/postinstall/xinit.sh" as - even if this worked -
>>> I would prefer to canvass opinion on this minor glitch.
>>> All the same - the glitch is recent, despite being minor .. ..
> 
>> What filesystem is the drive formatted as: NTFS, ExFAT, FAT32, or other?
>> Try rerunning the xinit postinstall script as follows and report the failing
>> command(s) and error messages:
>> 	$ CYGWINFORALL=-A /bin/sh -vx /etc/postinstall/xinit.sh
> 
> Thank you!
> 1. The identical error msg occurs on all of NTFS, FAT32, exFAT file systems.
> 2. The output from your test command is identical on all file systems,
> 3. The failing commands are the two separate "case .. mkdir .. mkshortcut" sequences that occur
> at the end of the xinit.sh script, with consequent error notification as follows:
> 
> case $(uname -s) in *-WOW*) wow64=" (32-bit)" ;; esac
> + case $(uname -s) in
> ++ uname -s
> /usr/bin/mkdir -p "$(/usr/bin/cygpath $CYGWINFORALL -P)/Cygwin-X${wow64}"
> ++ /usr/bin/cygpath -A -P
> + /usr/bin/mkdir -p '/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/Cygwin-X'
> /usr/bin/mkshortcut $CYGWINFORALL -P -w / -i /usr/bin/xwin-xdg-menu.exe -n "Cygwin-X${wow64}/XWin Server" -a "--quote /usr/bin/bash.exe
>   -l -c \"cd; exec /usr/bin/startxwin\"" /usr/bin/run.exe
> + /usr/bin/mkshortcut -A -P -w / -i /usr/bin/xwin-xdg-menu.exe -n 'Cygwin-X/XWin Server' -a '--quote /usr/bin/bash.exe
>   -l -c "cd; exec /usr/bin/startxwin"' /usr/bin/run.exe
> mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/Cygwin-X/XWin Server.lnk" failed;
> does the target directory exist?
> 
> case $(uname -s) in *-WOW*) wow64=" (32-bit)" ;; esac
> + case $(uname -s) in
> ++ uname -s
> /usr/bin/mkdir -p "$(/usr/bin/cygpath $CYGWINFORALL -P)/Cygwin-X${wow64}"
> ++ /usr/bin/cygpath -A -P
> + /usr/bin/mkdir -p '/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/Cygwin-X'
> /usr/bin/mkshortcut $CYGWINFORALL -P -w / -i /usr/bin/XWin.exe -n "Cygwin-X${wow64}/User script" -a "--quote /usr/bin/bash.exe
>   -l -c \"cd; XSESSION_ICON= exec /usr/bin/startx /etc/X11/xinit/Xsession xinit-compat\"" /usr/bin/run.exe
> + /usr/bin/mkshortcut -A -P -w / -i /usr/bin/XWin.exe -n 'Cygwin-X/User script' -a '--quote /usr/bin/bash.exe
>   -l -c "cd; XSESSION_ICON= exec /usr/bin/startx /etc/X11/xinit/Xsession xinit-compat"' /usr/bin/run.exe
> mkshortcut: Saving "/cygdrive/c/ProgramData/Microsoft/Windows/Start Menu/Programs/Cygwin-X/User script.lnk" failed;
>   does the target directory exist?
> 
> When I used Explorer to visit C:\ProgramData\Microsoft\Windows\Start Menu\Cygwin-X I was told:
> "You don't currently have permission to access this folder"
> and clicking on Continue to get access I was told:
> "You have been denied permission to access this folder"
> There was then offered an option to edit Permissions which I didn't feel like pursuing.
> 
> (I am the Administrator on my own standalone Windows machine. The denial of access to Cygwin-X feels odd.
> PS I also have Cygwin32 installed and running. I _am_ permitted access to the equivalent folder Cygwin-X (32-bit).)

Please try running the following command/s, under Cygwin 32 and 64, and posting 
the outputs:

$ for p in "`cygpath -A -P -U`"{,/Cygwin-X}; do for c in 'lsattr -d' 'ls -dl' 
getfacl; do $c "$p"; echo; done; icacls "`cygpath -m "$p"`"; done

[I just typoed Cygwin 23 and thought - could that be a package of Cygwin, Perl, 
Python, etc. for DNA analysis? ;^> ]

-- 
Take care. Thanks, Brian Inglis              Calgary, Alberta, Canada

La perfection est atteinte                   Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter  not when there is no more to add
mais lorsqu'il n'y a plus rien à retirer     but when there is no more to cut
                                 -- Antoine de Saint-Exupéry

^ permalink raw reply	[flat|nested] 8+ messages in thread

* RE: New installation of Cygwin64: xinit.sh exit code 3
  2023-10-22  4:46   ` Fergus Daly
  2023-10-22 13:47     ` Brian Inglis
@ 2023-10-23 12:05     ` Fergus Daly
  2023-10-23 15:41       ` Brian Inglis
  1 sibling, 1 reply; 8+ messages in thread
From: Fergus Daly @ 2023-10-23 12:05 UTC (permalink / raw)
  To: 'cygwin@cygwin.com'; +Cc: Fergus Daly

<< Detail >>

>> When I used Explorer to visit C:\ProgramData\Microsoft\Windows\Start Menu\Cygwin-X I was told:
>> "You don't currently have permission to access this folder"
>> and clicking on Continue to get access I was told:
>> "You have been denied permission to access this folder"
>>There was then offered an option to edit Permissions which I didn't feel like pursuing.
>> (I am the Administrator on my own standalone Windows machine. The denial of access to Cygwin-X feels odd.
>> PS I also have Cygwin32 installed and running. I _am_ permitted access to the equivalent folder Cygwin-X (32-bit).)

> Please try running the following command/s, under Cygwin 32 and 64, and posting 
> the outputs:

> $ for p in "`cygpath -A -P -U`"{,/Cygwin-X}; do for c in 'lsattr -d' 'ls -dl' 
> getfacl; do $c "$p"; echo; done; icacls "`cygpath -m "$p"`"; done

Thank you. (Again.)
1. Actually before reading this I had deleted both folders
(successfully, despite not being permitted entry into one 
of them) and the re-ran the xinit installation with no
bother at all. 
I'm guessing the Permissions glitch resulted from some local
recent accidental keypress or sequence.
2. icacls? Haven't got this though I have got getfacl; found icacl in 
"Search packages" under libattica-devel and ng-spice-debuginfo?    

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: New installation of Cygwin64: xinit.sh exit code 3
  2023-10-23 12:05     ` Fergus Daly
@ 2023-10-23 15:41       ` Brian Inglis
  2024-05-10  0:55         ` Frank-Ulrich Sommer
  0 siblings, 1 reply; 8+ messages in thread
From: Brian Inglis @ 2023-10-23 15:41 UTC (permalink / raw)
  To: cygwin

On 2023-10-23 06:05, Fergus Daly via Cygwin wrote:
> << Detail >>
> 
>>> When I used Explorer to visit C:\ProgramData\Microsoft\Windows\Start Menu\Cygwin-X I was told:
>>> "You don't currently have permission to access this folder"
>>> and clicking on Continue to get access I was told:
>>> "You have been denied permission to access this folder"
>>> There was then offered an option to edit Permissions which I didn't feel like pursuing.
>>> (I am the Administrator on my own standalone Windows machine. The denial of access to Cygwin-X feels odd.
>>> PS I also have Cygwin32 installed and running. I _am_ permitted access to the equivalent folder Cygwin-X (32-bit).)
> 
>> Please try running the following command/s, under Cygwin 32 and 64, and posting
>> the outputs:
> 
>> $ for p in "`cygpath -A -P -U`"{,/Cygwin-X}; do for c in 'lsattr -d' 'ls -dl'
>> getfacl; do $c "$p"; echo; done; icacls "`cygpath -m "$p"`"; done
> 
> Thank you. (Again.)
> 1. Actually before reading this I had deleted both folders
> (successfully, despite not being permitted entry into one
> of them) and the re-ran the xinit installation with no
> bother at all.
> I'm guessing the Permissions glitch resulted from some local
> recent accidental keypress or sequence.
> 2. icacls? Haven't got this though I have got getfacl; found icacl in
> "Search packages" under libattica-devel and ng-spice-debuginfo?

	$ /proc/cygdrive/c/WINDOWS/system32/icacls /?

-- 
Take care. Thanks, Brian Inglis              Calgary, Alberta, Canada

La perfection est atteinte                   Perfection is achieved
non pas lorsqu'il n'y a plus rien à ajouter  not when there is no more to add
mais lorsqu'il n'y a plus rien à retirer     but when there is no more to cut
                                 -- Antoine de Saint-Exupéry

^ permalink raw reply	[flat|nested] 8+ messages in thread

* Re: New installation of Cygwin64: xinit.sh exit code 3
  2023-10-23 15:41       ` Brian Inglis
@ 2024-05-10  0:55         ` Frank-Ulrich Sommer
  0 siblings, 0 replies; 8+ messages in thread
From: Frank-Ulrich Sommer @ 2024-05-10  0:55 UTC (permalink / raw)
  To: cygwin

I seem to have almost excatly the same problem except that I could not solve it by removing the Cygwin-X folder. In this case during the reinstallation of the xinit package the folder is recreated again and then the original error message (xinit.sh exit code 3) reappears. The directory again has strange permissions  when checked with Windows Explorer and I am not allowed the enter it or see its contents before resetting the security settings.

When doing an "ls -l" (within Cygwin) in the "Start Menu" folder the group and owner for the Cygwin-X directory seem to be reversed compared to other folders manually created from Windows Explorer (i.e. the user name appears in the group column and vice versa) but I'm not sure if this is important:

d---rwxr-x+ 1 myusername Administratoren                0 May 10 02:27  Cygwin-X

For all other folders the group is displayed before the username.

I had to fix the security settings for the Cygwin-X folder and then manually execute the last two "mkshortcut" commands from "/etc/postinstall/xinit.sh" (replacing $CYGWINFORALL with "-A" and ${wow64} with an empty string).

Should this be the only problem and should my "fix" be correct? And is there anything I can do to help find the cause for this problem?



On 23.10.2023 17:41, Brian Inglis via Cygwin wrote:
> On 2023-10-23 06:05, Fergus Daly via Cygwin wrote:
>> << Detail >>
>>
>>>> When I used Explorer to visit C:\ProgramData\Microsoft\Windows\Start Menu\Cygwin-X I was told:
>>>> "You don't currently have permission to access this folder"
>>>> and clicking on Continue to get access I was told:
>>>> "You have been denied permission to access this folder"
>>>> There was then offered an option to edit Permissions which I didn't feel like pursuing.
>>>> (I am the Administrator on my own standalone Windows machine. The denial of access to Cygwin-X feels odd.
>>>> PS I also have Cygwin32 installed and running. I _am_ permitted access to the equivalent folder Cygwin-X (32-bit).)
>>
>>> Please try running the following command/s, under Cygwin 32 and 64, and posting
>>> the outputs:
>>
>>> $ for p in "`cygpath -A -P -U`"{,/Cygwin-X}; do for c in 'lsattr -d' 'ls -dl'
>>> getfacl; do $c "$p"; echo; done; icacls "`cygpath -m "$p"`"; done
>>
>> Thank you. (Again.)
>> 1. Actually before reading this I had deleted both folders
>> (successfully, despite not being permitted entry into one
>> of them) and the re-ran the xinit installation with no
>> bother at all.
>> I'm guessing the Permissions glitch resulted from some local
>> recent accidental keypress or sequence.
>> 2. icacls? Haven't got this though I have got getfacl; found icacl in
>> "Search packages" under libattica-devel and ng-spice-debuginfo?
>
>     $ /proc/cygdrive/c/WINDOWS/system32/icacls /?
>


^ permalink raw reply	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2024-05-10  0:55 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-10-21  9:57 New installation of Cygwin64: xinit.sh exit code 3 Fergus Daly
2023-10-21 10:52 ` Fergus Daly
2023-10-21 16:21   ` Brian Inglis
2023-10-22  4:46   ` Fergus Daly
2023-10-22 13:47     ` Brian Inglis
2023-10-23 12:05     ` Fergus Daly
2023-10-23 15:41       ` Brian Inglis
2024-05-10  0:55         ` Frank-Ulrich Sommer

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).