public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* Windows hostname change fails in recent versions of Cygwin (since 1.7.28)
@ 2014-04-14 22:28 Wedge Jarrad
  2014-04-14 22:39 ` Larry Hall (Cygwin)
  0 siblings, 1 reply; 4+ messages in thread
From: Wedge Jarrad @ 2014-04-14 22:28 UTC (permalink / raw)
  To: cygwin

[-- Attachment #1: Type: text/plain, Size: 2061 bytes --]

Hello all,

The following command used to allow me to change the hostname of a Windows
machine:

wmic computersystem where name=\"$COMPUTERNAME\" call rename name=newname

With new installs of Cygwin this seems to have stopped working. Installs from
as recently as mid January of this year seem to work however by early March it
no longer seemed to work. Last known good version (as reported by uname -r) is
1.7.27(0.271/5/3). Known not working by 1.7.28(0.271/5/3). Doesn't work on the
version that I installed last week either (1.7.29(0.272/5/3)). Using 64-bit
versions in all cases. Appears to be a problem on 64-bit versions of Windows 7
and 8. Have not tested on other versions of Windows.

Output from working system:

$ wmic computersystem where name=\"$COMPUTERNAME\" call rename name=newname
Executing (\\OLDNAME\ROOT\CIMV2:Win32_ComputerSystem.Name="OLDNAME")->rename()
Method execution successful.
Out Parameters:
instance of __PARAMETERS
{
        ReturnValue = 0;
};

And indeed the hostname is changed to "newname" after a reboot.

Output received on nonworking system:

$ wmic computersystem where name=\"$COMPUTERNAME\" call rename name=newname
Executing (\\OLDNAME\ROOT\CIMV2:Win32_ComputerSystem.Name="OLDNAME")->rename()
Method execution successful.
Out Parameters:
instance of __PARAMETERS
{
        ReturnValue = 87;
};

Despite the fact that it says that the method execution was successful, the
ReturnValue indicates that it has actually encountered an error. Upon reboot
the hostname remains as it was before running the command.

The same command, when run from the native windows cmd.exe shell works as
expected. Executing the command with cmd /c also results in failure. As far as
I can tell nothing has changed on my end except for the Cygwin version. Same
version of Windows (installed from the same disc).

If anyone can confirm this as a bug in Cygwin (as opposed to user error on my
part), or, better yet, suggest a workaround I'd be most appreciative.

Attached is 'cygcheck -s -v -r' output from a non-working system.

-Jarrad

[-- Attachment #2: cygcheck.out --]
[-- Type: application/octet-stream, Size: 20655 bytes --]


Cygwin Configuration Diagnostics
Current System Time: Mon Apr 14 20:57:37 2014

Windows 7 Enterprise Ver 6.1 Build 7601 Service Pack 1

Path:	C:\cygwin64\usr\local\bin
	C:\cygwin64\bin
	C:\Windows\system32
	C:\Windows
	C:\Windows\System32\Wbem
	C:\Windows\System32\WindowsPowerShell\v1.0
	C:\cygwin64\bin

Output from C:\cygwin64\bin\id.exe
UID: 500(Administrator) GID: 513(None)
513(None)               0(root)                 544(Administrators)
545(Users)

SysDir: C:\Windows\system32
WinDir: C:\Windows

USER = 'Administrator'
PWD = '/home/Administrator'
HOME = '/home/Administrator'

HOMEPATH = '\cygwin64\home\Administrator'
MANPATH = '/usr/local/man:/usr/share/man:/usr/man:'
HOSTNAME = 'oldname'
TERM = 'xterm'
SHELL = '/bin/bash'
WINDIR = 'C:\Windows'
SSH_CLIENT = '10.50.184.37 49653 22'
OLDPWD = '/home/Administrator'
USERDOMAIN = 'oldname'
SSH_TTY = '/dev/pty1'
OS = 'Windows_NT'
ALLUSERSPROFILE = 'C:\ProgramData'
USERNAME = 'Administrator'
MAIL = '/var/spool/mail//Administrator'
SYSTEMDRIVE = 'C:'
LANG = 'ar_SA.UTF-8'
USERPROFILE = 'C:\Users\Administrator'
TZ = 'Asia/Riyadh'
PS1 = '\[\e]0;\w\a\]\n\[\e[32m\]\u@\h \[\e[33m\]\w\[\e[0m\]\n\$ '
LOGONSERVER = '\\OLDNAME'
SHLVL = '1'
PATHEXT = '.COM;.EXE;.BAT;.CMD;.VBS;.VBE;.JS;.JSE;.WSF;.WSH;.MSC'
HOMEDRIVE = 'C:'
COMSPEC = 'C:\Windows\system32\cmd.exe'
TMP = '/tmp'
LOGNAME = 'Administrator'
SYSTEMROOT = 'C:\Windows'
PRINTER = 'Microsoft XPS Document Writer'
SSH_CONNECTION = '10.50.184.37 49653 10.50.184.30 22'
INFOPATH = '/usr/local/info:/usr/share/info:/usr/info:'
PROGRAMFILES = 'C:\Program Files'
COMPUTERNAME = 'OLDNAME'
_ = '/usr/bin/cygcheck'

HKEY_CURRENT_USER\Software\Cygwin
HKEY_CURRENT_USER\Software\Cygwin\Program Options
HKEY_CURRENT_USER\Software\Cygwin\setup
HKEY_LOCAL_MACHINE\SOFTWARE\Cygwin
HKEY_LOCAL_MACHINE\SOFTWARE\Cygwin\Installations
  (default) = '\??\C:\cygwin64'
HKEY_LOCAL_MACHINE\SOFTWARE\Cygwin\Program Options
HKEY_LOCAL_MACHINE\SOFTWARE\Cygwin\setup
  (default) = 'C:\cygwin64'

obcaseinsensitive set to 1

Cygwin installations found in the registry:
  System: Key: e022582115c10879 Path: C:\cygwin64

a:  fd             N/A    N/A                    
c:  hd  NTFS     32665Mb  32% CP CS UN PA FC     
d:  cd             N/A    N/A                    

C:\cygwin64      /          system  binary,auto
C:\cygwin64\bin  /usr/bin   system  binary,auto
C:\cygwin64\lib  /usr/lib   system  binary,auto
cygdrive prefix  /cygdrive  user    binary,posix=0,auto

Found: C:\cygwin64\bin\awk
Found: C:\cygwin64\bin\awk
 -> C:\cygwin64\bin\gawk.exe
Found: C:\cygwin64\bin\bash.exe
Found: C:\cygwin64\bin\bash.exe
Found: C:\cygwin64\bin\cat.exe
Found: C:\cygwin64\bin\cat.exe
Found: C:\cygwin64\bin\cp.exe
Found: C:\cygwin64\bin\cp.exe
Not Found: cpp (good!)
Not Found: crontab
Found: C:\cygwin64\bin\find.exe
Found: C:\Windows\system32\find.exe
Warning: C:\cygwin64\bin\find.exe hides C:\Windows\system32\find.exe
Found: C:\cygwin64\bin\find.exe
Not Found: gcc
Not Found: gdb
Found: C:\cygwin64\bin\grep.exe
Found: C:\cygwin64\bin\grep.exe
Found: C:\cygwin64\bin\kill.exe
Found: C:\cygwin64\bin\kill.exe
Not Found: ld
Found: C:\cygwin64\bin\ls.exe
Found: C:\cygwin64\bin\ls.exe
Not Found: make
Found: C:\cygwin64\bin\mv.exe
Found: C:\cygwin64\bin\mv.exe
Not Found: patch
Not Found: perl
Found: C:\cygwin64\bin\rm.exe
Found: C:\cygwin64\bin\rm.exe
Found: C:\cygwin64\bin\sed.exe
Found: C:\cygwin64\bin\sed.exe
Found: C:\cygwin64\bin\ssh.exe
Found: C:\cygwin64\bin\ssh.exe
Found: C:\cygwin64\bin\sh.exe
Found: C:\cygwin64\bin\sh.exe
Found: C:\cygwin64\bin\tar.exe
Found: C:\cygwin64\bin\tar.exe
Found: C:\cygwin64\bin\test.exe
Found: C:\cygwin64\bin\test.exe
Found: C:\cygwin64\bin\vi.exe
Found: C:\cygwin64\bin\vi.exe
Not Found: vim

   38k 2013/07/19 C:\cygwin64\bin\cygargp-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygargp-0.dll" v0.0 ts=2013-07-19 15:07
  510k 2014/03/20 C:\cygwin64\bin\cygasn1-8.dll - os=4.0 img=0.0 sys=5.2
                  "cygasn1-8.dll" v0.0 ts=2014-03-20 04:54
   16k 2013/03/26 C:\cygwin64\bin\cygattr-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygattr-1.dll" v0.0 ts=2013-03-26 18:26
   64k 2013/03/07 C:\cygwin64\bin\cygbz2-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygbz2-1.dll" v0.0 ts=2013-03-07 02:54
   12k 2013/03/11 C:\cygwin64\bin\cygcom_err-2.dll - os=4.0 img=0.0 sys=5.2
                  "cygcom_err-2.dll" v0.0 ts=2013-03-11 03:59
    9k 2013/03/07 C:\cygwin64\bin\cygcrypt-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygcrypt-0.dll" v0.0 ts=2013-03-07 09:29
 1749k 2014/04/08 C:\cygwin64\bin\cygcrypto-1.0.0.dll - os=4.0 img=0.0 sys=5.2
                  "cygcrypto-1.0.0.dll" v0.0 ts=1970-01-01 00:00
  154k 2013/10/20 C:\cygwin64\bin\cygedit-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygedit-0.dll" v0.0 ts=2013-10-20 21:56
   22k 2013/05/12 C:\cygwin64\bin\cygffi-6.dll - os=4.0 img=0.0 sys=5.2
                  "cygffi-6.dll" v0.0 ts=2013-05-12 22:53
   53k 2013/05/06 C:\cygwin64\bin\cygformw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygformw-10.dll" v0.0 ts=2013-05-06 08:10
   67k 2014/01/29 C:\cygwin64\bin\cyggcc_s-seh-1.dll - os=4.0 img=0.0 sys=5.2
                  "cyggcc_s-seh-1.dll" v0.0 ts=2014-01-29 00:47
  516k 2014/04/05 C:\cygwin64\bin\cyggmp-10.dll - os=4.0 img=0.0 sys=5.2
                  "cyggmp-10.dll" v0.0 ts=1970-01-01 00:00
  198k 2014/03/20 C:\cygwin64\bin\cyggssapi-3.dll - os=4.0 img=0.0 sys=5.2
                  "cyggssapi-3.dll" v0.0 ts=2014-03-20 06:15
   14k 2014/03/20 C:\cygwin64\bin\cygheimbase-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygheimbase-1.dll" v0.0 ts=2014-03-20 04:52
   24k 2014/03/20 C:\cygwin64\bin\cygheimntlm-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygheimntlm-0.dll" v0.0 ts=2014-03-20 06:13
   29k 2013/03/14 C:\cygwin64\bin\cyghistory7.dll - os=4.0 img=0.0 sys=5.2
                  "cyghistory7.dll" v0.0 ts=2013-03-14 11:14
  236k 2014/03/20 C:\cygwin64\bin\cyghx509-5.dll - os=4.0 img=0.0 sys=5.2
                  "cyghx509-5.dll" v0.0 ts=2014-03-20 04:55
  998k 2013/03/07 C:\cygwin64\bin\cygiconv-2.dll - os=4.0 img=0.0 sys=5.2
                  "cygiconv-2.dll" v0.0 ts=2013-03-07 03:03
   38k 2013/06/24 C:\cygwin64\bin\cygintl-8.dll - os=4.0 img=0.0 sys=5.2
                  "cygintl-8.dll" v0.0 ts=2013-06-24 04:36
   23k 2014/03/20 C:\cygwin64\bin\cygkafs-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygkafs-0.dll" v0.0 ts=2014-03-20 06:13
  403k 2014/03/20 C:\cygwin64\bin\cygkrb5-26.dll - os=4.0 img=0.0 sys=5.2
                  "cygkrb5-26.dll" v0.0 ts=2014-03-20 06:12
    6k 2014/04/07 C:\cygwin64\bin\cyglsa64.dll - os=4.0 img=0.0 sys=5.2
                  "cyglsa64.dll" v0.0 ts=2014-04-07 12:46
  129k 2013/03/07 C:\cygwin64\bin\cyglzma-5.dll - os=4.0 img=0.0 sys=5.2
                  "cyglzma-5.dll" v0.0 ts=2013-03-07 10:20
  107k 2014/03/27 C:\cygwin64\bin\cygmagic-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygmagic-1.dll" v0.0 ts=1970-01-01 00:00
   28k 2013/05/06 C:\cygwin64\bin\cygmenuw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygmenuw-10.dll" v0.0 ts=2013-05-06 08:10
  319k 2013/05/05 C:\cygwin64\bin\cygmpfr-4.dll - os=4.0 img=0.0 sys=5.2
                  "cygmpfr-4.dll" v0.0 ts=2013-05-05 13:40
   52k 2013/05/06 C:\cygwin64\bin\cygncurses++w-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygncurses++w-10.dll" v0.0 ts=2013-05-06 08:14
  295k 2013/05/06 C:\cygwin64\bin\cygncursesw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygncursesw-10.dll" v0.0 ts=2013-05-06 08:08
  207k 2014/03/13 C:\cygwin64\bin\cygp11-kit-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygp11-kit-0.dll" v0.0 ts=2014-03-13 03:35
   13k 2013/05/06 C:\cygwin64\bin\cygpanelw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygpanelw-10.dll" v0.0 ts=2013-05-06 08:09
  271k 2014/03/12 C:\cygwin64\bin\cygpcre-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygpcre-1.dll" v0.0 ts=2014-03-12 02:35
   41k 2013/10/21 C:\cygwin64\bin\cygpopt-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygpopt-0.dll" v0.0 ts=2013-10-21 21:52
  193k 2013/03/14 C:\cygwin64\bin\cygreadline7.dll - os=4.0 img=0.0 sys=5.2
                  "cygreadline7.dll" v0.0 ts=2013-03-14 11:14
   57k 2014/03/20 C:\cygwin64\bin\cygroken-18.dll - os=4.0 img=0.0 sys=5.2
                  "cygroken-18.dll" v0.0 ts=2014-03-20 04:53
  721k 2014/03/11 C:\cygwin64\bin\cygsqlite3-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygsqlite3-0.dll" v0.0 ts=2014-03-11 21:05
  377k 2014/04/08 C:\cygwin64\bin\cygssl-1.0.0.dll - os=4.0 img=0.0 sys=5.2
                  "cygssl-1.0.0.dll" v0.0 ts=1970-01-01 00:00
   11k 2014/01/29 C:\cygwin64\bin\cygssp-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygssp-0.dll" v0.0 ts=2014-01-29 01:14
  892k 2014/01/29 C:\cygwin64\bin\cygstdc++-6.dll - os=4.0 img=0.0 sys=5.2
                  "cygstdc++-6.dll" v0.0 ts=2014-01-29 00:57
   69k 2013/04/22 C:\cygwin64\bin\cygtasn1-6.dll - os=4.0 img=0.0 sys=5.2
                  "cygtasn1-6.dll" v0.0 ts=2013-04-22 01:25
   51k 2013/05/06 C:\cygwin64\bin\cygticw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygticw-10.dll" v0.0 ts=2013-05-06 08:08
  161k 2014/03/20 C:\cygwin64\bin\cygwind-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygwind-0.dll" v0.0 ts=2014-03-20 04:53
   30k 2013/11/15 C:\cygwin64\bin\cygwrap-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygwrap-0.dll" v0.0 ts=2013-11-15 19:58
   79k 2013/05/09 C:\cygwin64\bin\cygz.dll - os=4.0 img=0.0 sys=5.2
                  "cygz.dll" v0.0 ts=2013-05-09 22:20
 3073k 2014/04/07 C:\cygwin64\bin\cygwin1.dll - os=4.0 img=0.0 sys=5.2
                  "cygwin1.dll" v0.0 ts=1970-01-01 00:00
    Cygwin DLL version info:
        DLL version: 1.7.29
        DLL epoch: 19
        DLL old termios: 5
        DLL malloc env: 28
        Cygwin conv: 181
        API major: 0
        API minor: 272
        Shared data: 5
        DLL identifier: cygwin1
        Mount registry: 3
        Cygwin registry name: Cygwin
        Program options name: Program Options
        Installations name: Installations
        Cygdrive default prefix: 
        Build date: 
        Shared id: cygwin1S5

   38k 2013/07/19 C:\cygwin64\bin\cygargp-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygargp-0.dll" v0.0 ts=2013-07-19 15:07
  510k 2014/03/20 C:\cygwin64\bin\cygasn1-8.dll - os=4.0 img=0.0 sys=5.2
                  "cygasn1-8.dll" v0.0 ts=2014-03-20 04:54
   16k 2013/03/26 C:\cygwin64\bin\cygattr-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygattr-1.dll" v0.0 ts=2013-03-26 18:26
   64k 2013/03/07 C:\cygwin64\bin\cygbz2-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygbz2-1.dll" v0.0 ts=2013-03-07 02:54
   12k 2013/03/11 C:\cygwin64\bin\cygcom_err-2.dll - os=4.0 img=0.0 sys=5.2
                  "cygcom_err-2.dll" v0.0 ts=2013-03-11 03:59
    9k 2013/03/07 C:\cygwin64\bin\cygcrypt-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygcrypt-0.dll" v0.0 ts=2013-03-07 09:29
 1749k 2014/04/08 C:\cygwin64\bin\cygcrypto-1.0.0.dll - os=4.0 img=0.0 sys=5.2
                  "cygcrypto-1.0.0.dll" v0.0 ts=1970-01-01 00:00
  154k 2013/10/20 C:\cygwin64\bin\cygedit-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygedit-0.dll" v0.0 ts=2013-10-20 21:56
   22k 2013/05/12 C:\cygwin64\bin\cygffi-6.dll - os=4.0 img=0.0 sys=5.2
                  "cygffi-6.dll" v0.0 ts=2013-05-12 22:53
   53k 2013/05/06 C:\cygwin64\bin\cygformw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygformw-10.dll" v0.0 ts=2013-05-06 08:10
   67k 2014/01/29 C:\cygwin64\bin\cyggcc_s-seh-1.dll - os=4.0 img=0.0 sys=5.2
                  "cyggcc_s-seh-1.dll" v0.0 ts=2014-01-29 00:47
  516k 2014/04/05 C:\cygwin64\bin\cyggmp-10.dll - os=4.0 img=0.0 sys=5.2
                  "cyggmp-10.dll" v0.0 ts=1970-01-01 00:00
  198k 2014/03/20 C:\cygwin64\bin\cyggssapi-3.dll - os=4.0 img=0.0 sys=5.2
                  "cyggssapi-3.dll" v0.0 ts=2014-03-20 06:15
   14k 2014/03/20 C:\cygwin64\bin\cygheimbase-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygheimbase-1.dll" v0.0 ts=2014-03-20 04:52
   24k 2014/03/20 C:\cygwin64\bin\cygheimntlm-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygheimntlm-0.dll" v0.0 ts=2014-03-20 06:13
   29k 2013/03/14 C:\cygwin64\bin\cyghistory7.dll - os=4.0 img=0.0 sys=5.2
                  "cyghistory7.dll" v0.0 ts=2013-03-14 11:14
  236k 2014/03/20 C:\cygwin64\bin\cyghx509-5.dll - os=4.0 img=0.0 sys=5.2
                  "cyghx509-5.dll" v0.0 ts=2014-03-20 04:55
  998k 2013/03/07 C:\cygwin64\bin\cygiconv-2.dll - os=4.0 img=0.0 sys=5.2
                  "cygiconv-2.dll" v0.0 ts=2013-03-07 03:03
   38k 2013/06/24 C:\cygwin64\bin\cygintl-8.dll - os=4.0 img=0.0 sys=5.2
                  "cygintl-8.dll" v0.0 ts=2013-06-24 04:36
   23k 2014/03/20 C:\cygwin64\bin\cygkafs-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygkafs-0.dll" v0.0 ts=2014-03-20 06:13
  403k 2014/03/20 C:\cygwin64\bin\cygkrb5-26.dll - os=4.0 img=0.0 sys=5.2
                  "cygkrb5-26.dll" v0.0 ts=2014-03-20 06:12
    6k 2014/04/07 C:\cygwin64\bin\cyglsa64.dll - os=4.0 img=0.0 sys=5.2
                  "cyglsa64.dll" v0.0 ts=2014-04-07 12:46
  129k 2013/03/07 C:\cygwin64\bin\cyglzma-5.dll - os=4.0 img=0.0 sys=5.2
                  "cyglzma-5.dll" v0.0 ts=2013-03-07 10:20
  107k 2014/03/27 C:\cygwin64\bin\cygmagic-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygmagic-1.dll" v0.0 ts=1970-01-01 00:00
   28k 2013/05/06 C:\cygwin64\bin\cygmenuw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygmenuw-10.dll" v0.0 ts=2013-05-06 08:10
  319k 2013/05/05 C:\cygwin64\bin\cygmpfr-4.dll - os=4.0 img=0.0 sys=5.2
                  "cygmpfr-4.dll" v0.0 ts=2013-05-05 13:40
   52k 2013/05/06 C:\cygwin64\bin\cygncurses++w-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygncurses++w-10.dll" v0.0 ts=2013-05-06 08:14
  295k 2013/05/06 C:\cygwin64\bin\cygncursesw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygncursesw-10.dll" v0.0 ts=2013-05-06 08:08
  207k 2014/03/13 C:\cygwin64\bin\cygp11-kit-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygp11-kit-0.dll" v0.0 ts=2014-03-13 03:35
   13k 2013/05/06 C:\cygwin64\bin\cygpanelw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygpanelw-10.dll" v0.0 ts=2013-05-06 08:09
  271k 2014/03/12 C:\cygwin64\bin\cygpcre-1.dll - os=4.0 img=0.0 sys=5.2
                  "cygpcre-1.dll" v0.0 ts=2014-03-12 02:35
   41k 2013/10/21 C:\cygwin64\bin\cygpopt-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygpopt-0.dll" v0.0 ts=2013-10-21 21:52
  193k 2013/03/14 C:\cygwin64\bin\cygreadline7.dll - os=4.0 img=0.0 sys=5.2
                  "cygreadline7.dll" v0.0 ts=2013-03-14 11:14
   57k 2014/03/20 C:\cygwin64\bin\cygroken-18.dll - os=4.0 img=0.0 sys=5.2
                  "cygroken-18.dll" v0.0 ts=2014-03-20 04:53
  721k 2014/03/11 C:\cygwin64\bin\cygsqlite3-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygsqlite3-0.dll" v0.0 ts=2014-03-11 21:05
  377k 2014/04/08 C:\cygwin64\bin\cygssl-1.0.0.dll - os=4.0 img=0.0 sys=5.2
                  "cygssl-1.0.0.dll" v0.0 ts=1970-01-01 00:00
   11k 2014/01/29 C:\cygwin64\bin\cygssp-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygssp-0.dll" v0.0 ts=2014-01-29 01:14
  892k 2014/01/29 C:\cygwin64\bin\cygstdc++-6.dll - os=4.0 img=0.0 sys=5.2
                  "cygstdc++-6.dll" v0.0 ts=2014-01-29 00:57
   69k 2013/04/22 C:\cygwin64\bin\cygtasn1-6.dll - os=4.0 img=0.0 sys=5.2
                  "cygtasn1-6.dll" v0.0 ts=2013-04-22 01:25
   51k 2013/05/06 C:\cygwin64\bin\cygticw-10.dll - os=4.0 img=0.0 sys=5.2
                  "cygticw-10.dll" v0.0 ts=2013-05-06 08:08
  161k 2014/03/20 C:\cygwin64\bin\cygwind-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygwind-0.dll" v0.0 ts=2014-03-20 04:53
   30k 2013/11/15 C:\cygwin64\bin\cygwrap-0.dll - os=4.0 img=0.0 sys=5.2
                  "cygwrap-0.dll" v0.0 ts=2013-11-15 19:58
   79k 2013/05/09 C:\cygwin64\bin\cygz.dll - os=4.0 img=0.0 sys=5.2
                  "cygz.dll" v0.0 ts=2013-05-09 22:20
 3073k 2014/04/07 C:\cygwin64\bin\cygwin1.dll - os=4.0 img=0.0 sys=5.2
                  "cygwin1.dll" v0.0 ts=1970-01-01 00:00
    Cygwin DLL version info:
        DLL version: 1.7.29
        DLL epoch: 19
        DLL old termios: 5
        DLL malloc env: 28
        Cygwin conv: 181
        API major: 0
        API minor: 272
        Shared data: 5
        DLL identifier: cygwin1
        Mount registry: 3
        Cygwin registry name: Cygwin
        Program options name: Program Options
        Installations name: Installations
        Cygdrive default prefix: 
        Build date: 
        Shared id: cygwin1S5


Service             : sshd                
Display name        : CYGWIN sshd
Current State       : Running
Controls Accepted   : Stop
Command             : /usr/sbin/sshd -D
stdin path          : /dev/null
stdout path         : /var/log/sshd.log
stderr path         : /var/log/sshd.log
Process Type        : Own Process
Startup             : Automatic
Dependencies        : tcpip
Account             : .\cyg_server


Cygwin Package Information
Last downloaded files to: C:\Users\Administrator\Desktop
Last downloaded files from: http://lug.mtu.edu/cygwin/

Package              Version         Status
_autorebase          000130-1        OK
alternatives         1.3.30c-10      OK
base-cygwin          3.3-1           OK
base-files           4.1-1           OK
bash                 4.1.11-2        OK
bzip2                1.0.6-2         OK
ca-certificates      1.97-1          OK
coreutils            8.15-3          OK
csih                 0.9.7-1         OK
cygrunsrv            1.50-1          OK
cygutils             1.4.14-1        OK
cygwin               1.7.29-2        OK
dash                 0.5.7-4         OK
diffutils            3.3-1           OK
editrights           1.02-1          OK
file                 5.18-1          OK
findutils            4.5.11-1        OK
gawk                 4.1.0-1         OK
getent               2.18.90-1       OK
grep                 2.16-1          OK
groff                1.22.2-2        OK
gzip                 1.4-1           OK
hostname             3.13-1          OK
ipc-utils            1.0-2           OK
less                 458-1           OK
libargp              20110921-2      OK
libasn1_8            1.5.3-1         OK
libattr1             2.4.46-1        OK
libbz2_1             1.0.6-2         OK
libcom_err2          1.42.7-1        OK
libcrypt0            1.1-1           OK
libedit0             20130712-1      OK
libffi6              3.0.13-1        OK
libgcc1              4.8.2-3         OK
libgmp10             6.0.0a-1        OK
libgssapi3           1.5.3-1         OK
libheimbase1         1.5.3-1         OK
libheimntlm0         1.5.3-1         OK
libhx509_5           1.5.3-1         OK
libiconv2            1.14-1          OK
libintl8             0.18.1.1-3      OK
libkafs0             1.5.3-1         OK
libkrb5_26           1.5.3-1         OK
liblzma5             5.0.4-1         OK
libmpfr4             3.1.2-1         OK
libncursesw10        5.9-4           OK
libopenssl100        1.0.1g-1        OK
libp11-kit0          0.20.2-1        OK
libpcre1             8.34-1          OK
Empty package libpopt0
libpopt0             1.16-1          OK
libreadline7         6.2-1           OK
libroken18           1.5.3-1         OK
libsqlite3_0         3.8.4.1-1       OK
libssp0              4.8.2-3         OK
libstdc++6           4.8.2-3         OK
libtasn1_6           3.3-1           OK
libwind0             1.5.3-1         OK
libwrap0             7.6-22          OK
login                1.10-10         OK
man                  1.6g-2          OK
mintty               1.2-beta1-1     OK
openssh              6.6p1-1         OK
p11-kit              0.20.2-1        OK
p11-kit-trust        0.20.2-1        OK
popt                 1.16-1          OK
rebase               4.4.1-1         OK
run                  1.3.0-1         OK
sed                  4.2.2-3         OK
tar                  1.26-1          OK
terminfo             5.9-4           OK
tzcode               2013c-1         OK
vim-minimal          7.4.182-1       OK
which                2.20-2          OK
xz                   5.0.4-1         OK
zlib0                1.2.8-1         OK
Use -h to see help about each section

[-- Attachment #3: Type: text/plain, Size: 218 bytes --]

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows hostname change fails in recent versions of Cygwin (since 1.7.28)
  2014-04-14 22:28 Windows hostname change fails in recent versions of Cygwin (since 1.7.28) Wedge Jarrad
@ 2014-04-14 22:39 ` Larry Hall (Cygwin)
  2014-04-14 23:35   ` Andrey Repin
  0 siblings, 1 reply; 4+ messages in thread
From: Larry Hall (Cygwin) @ 2014-04-14 22:39 UTC (permalink / raw)
  To: cygwin

On 04/14/2014 06:28 PM, Wedge Jarrad wrote:
> Hello all,
>
> The following command used to allow me to change the hostname of a Windows
> machine:
>
> wmic computersystem where name=\"$COMPUTERNAME\" call rename name=newname
>
> With new installs of Cygwin this seems to have stopped working...

OK maybe I'm just missing something but what part of the above uses Cygwin?

--
Larry

_____________________________________________________________________

A: Yes.
 > Q: Are you sure?
 >> A: Because it reverses the logical flow of conversation.
 >>> Q: Why is top posting annoying in email?


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows hostname change fails in recent versions of Cygwin (since 1.7.28)
  2014-04-14 22:39 ` Larry Hall (Cygwin)
@ 2014-04-14 23:35   ` Andrey Repin
  2014-04-15  0:06     ` Wedge Jarrad
  0 siblings, 1 reply; 4+ messages in thread
From: Andrey Repin @ 2014-04-14 23:35 UTC (permalink / raw)
  To: Larry Hall (Cygwin)

Greetings, Larry Hall (Cygwin)!

>> The following command used to allow me to change the hostname of a Windows
>> machine:
>>
>> wmic computersystem where name=\"$COMPUTERNAME\" call rename name=newname
>>
>> With new installs of Cygwin this seems to have stopped working...

> OK maybe I'm just missing something but what part of the above uses Cygwin?

Shell prompt.
The user were able to execute specific command with previous versions of
Cygwin1.dll, but unable now.

@Wedge, there was some changes around handling '=', which is SUDDENLY
considered a separator character (that is, on par with space) for CMD.exe
batch files parameters.
I can't recall the exact dates, sorry.

Also, is the escaping of quotation marks around computer name necessary?
Try without them.


--
WBR,
Andrey Repin (anrdaemon@yandex.ru) 15.04.2014, <03:23>

Sorry for my terrible english...


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

* Re: Windows hostname change fails in recent versions of Cygwin (since 1.7.28)
  2014-04-14 23:35   ` Andrey Repin
@ 2014-04-15  0:06     ` Wedge Jarrad
  0 siblings, 0 replies; 4+ messages in thread
From: Wedge Jarrad @ 2014-04-15  0:06 UTC (permalink / raw)
  To: cygwin

Thank you for the replies.

>>> The following command used to allow me to change the hostname of a Windows
>>> machine:
>>>
>>> wmic computersystem where name=\"$COMPUTERNAME\" call rename name=newname
>>>
>>> With new installs of Cygwin this seems to have stopped working...
>
>> OK maybe I'm just missing something but what part of the above uses Cygwin?
>
> Shell prompt.
> The user were able to execute specific command with previous versions of
> Cygwin1.dll, but unable now.

Yes, exactly. The goal is to be able to SSH to the machine and run the command
but the same error occurs when running from a local Cygwin terminal.

> @Wedge, there was some changes around handling '=', which is SUDDENLY
> considered a separator character (that is, on par with space) for CMD.exe
> batch files parameters.
> I can't recall the exact dates, sorry.

Ok, that being the case what do I need to do to make the command execute
properly? Escaping? Quotes somewhere? I'm at a bit of a loss.

> Also, is the escaping of quotation marks around computer name necessary?
> Try without them.

Seems to be necessary. I get the following error when executing without quotes
and with un-escaped quotes. Even if I hard-code the current hostname rather
than using the $COMPUTERNAME variable.

ERROR:
Description = Invalid query

-Jarrad

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

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

end of thread, other threads:[~2014-04-15  0:06 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2014-04-14 22:28 Windows hostname change fails in recent versions of Cygwin (since 1.7.28) Wedge Jarrad
2014-04-14 22:39 ` Larry Hall (Cygwin)
2014-04-14 23:35   ` Andrey Repin
2014-04-15  0:06     ` Wedge Jarrad

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).