Recently I installed hyper-v on windows server 2008 enterprise R2.
I also installed win server 2008 enterprise R2 on hyper-v.
After a while I noticed that hyper-v was powered off.
This is happening after every start. Each time hyper-v is powering off.
Host system is fully updated and there is no error log neither in hosts event log nor in virtual machine system event log.
What should I do to avoid hyper-v automatic off?
Thanks
If you are using an expired Windows version, you could try to run (from 'cmd'):
slmgr -rearm
Or, if you have the right Windows key, but didn't bind it to this vm yet you can use the following command to bind the right key:
slmgr -ipk xxxx-xxxx-xxxxx-xxxx
If you meant to say the VM is being automatically shutdown, the "Admin" and "Analytic" event logs on host under "Applications and Services Logs\Microsoft\Windows\Hyper-V-VMMS" should have detailed information on what happened to the VM. You can also check "Hyper-V-Worker" events to see if you can find any anomalies. If not already enabled, you can enable the logs with following commands:
wevtutil sl Microsoft-Windows-Hyper-V-VMMS-Admin /e:false /ca:""
wevtutil sl Microsoft-Windows-Hyper-V-VMMS-Admin /e:true /q
wevtutil sl Microsoft-Windows-Hyper-V-VMMS-Analytic /e:false /ca:""
wevtutil sl Microsoft-Windows-Hyper-V-VMMS-Analytic /e:true /q
wevtutil sl Microsoft-Windows-Hyper-V-Worker-Admin /e:false /ca:""
wevtutil sl Microsoft-Windows-Hyper-V-Worker-Admin /e:true /q
wevtutil sl Microsoft-Windows-Hyper-V-Worker-Analytic /e:false /ca:""
wevtutil sl Microsoft-Windows-Hyper-V-Worker-Analytic /e:true /q
run slmgr.exe and specify the /ipk parameter.
Related
I have three new Raspberry Pis running this OS:
PRETTY_NAME="Raspbian GNU/Linux 11 (bullseye)"
NAME="Raspbian GNU/Linux"
VERSION_ID="11"
VERSION="11 (bullseye)"
VERSION_CODENAME=bullseye
ID=raspbian
ID_LIKE=debian
I cannot get Remote Desktop to connect properly. I have xrdp and all updates installed on the Pi. SSH is on and I can connect via a gitbash terminal fine. VNC connection is enabled and viewer connects just fine. I keep getting the following error after logging in to the Pi's ip address (192.168.4.84):
Connecting to sesman IP 127.0.0.1 port 3350
sesman connect ok sending
login info to session manager, please wait...
login successful for display 10
started connecting
connection problem, giving up
some problem
Per many other posts, I have tried:
restarting the xrdp service
adding auto lo to /etc/network/interfaces
reinstalling xrdp, vnc4server, and tightvnc in various orders per this answer.
adding allowed_users = anybody to /etc/X11/Xwrapper.config per this answer.
per this post, I tried purging xrdp, then purge vnc server, then reinstalling xrdp with no luck.
I tried installing an older version of xrdp per this answer, but the package is no longer available.
I tried adding this to sesman.ini, no luck
I have another Raspberry Pi running version 10 OS with no issues:
PRETTY_NAME="Raspbian GNU/Linux 10 (buster)"
NAME="Raspbian GNU/Linux"
VERSION_ID="10"
VERSION="10 (buster)"
VERSION_CODENAME=buster
ID=raspbian
ID_LIKE=debian
Any suggestions to get the newer OS working properly?
I have found the reason for the issue in this answer.
Turns out you cannot login twice with the same account using xrdp on Raspbian Bullseye (Debian 11). So you need to either disable autologin using "Raspberry Pi Configuration"/sudo raspi-config or create another user.
I created a second user and confirmed that this works. Thanks #A.J.Bauer
I got my Pi 4 today and ran into exactly your problem. Took me 1 hour to figure out how to fix, hope it can help:
Remove and purge all VNC server and then install/reinstall XRDP
sudo raspi-config
Go to (1) System Options -> S5 Boot/Auto Login -> select "B3 Desktop GUI - requiring user to login". It should works with this option. Otherwise you can give a try with the automatically logging in as pi user option.
Reboot and have fun !
The problem is that there is some process
still using the login name.
I solved this way:
add a new user, give sudo privs
rdp with that, it should work
deluser the previous one
kill any process that gives error in point 3 and repeat
set autologin to console no auto w/ raspi-config
reboot
rdp with new user
adduser the old one
rdp with that
you're good to go
I need to migrate application from Windows 2003 to Windows 2012 R2. There is a SNMP extension agent DLL (32-bit), that needs to be migrated as well.
I have installed SNMP service and tried to configure extension agent.
At first, I tried to do it in the same way as it was on Windows 2003 :
HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\SNMP\Parameters\ExtensionAgents :
"1"="SOFTWARE\\MyCompany\\MyAgent\\CurrentVersion"
and
HKEY_LOCAL_MACHINE\SOFTWARE\MyCompany\MyAgent\CurrentVersion :
"Pathname"="C:\bin\myagent".
But the extenstion agent did not start and in System event log I found this log :
The SNMP Service is ignoring extension agent dll C:\bin\myagent
because it is missing or misconfigured.
The file "myagent.dll" is present. So I tried to add "dll" extension to registry key with same result.
After some Internet research I found, that registry keys for 32-bit applications should be under Wow6432Node sud-tree. So I moved the configuration to registry tree :
HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\MyCompany\MyAgent\CurrentVersion
and changed the configuration on extension agent to point to correct registry sub-tree. After this, there is no error log in System event log, but DLL is not loaded by any process (checked by Process Explorer).
Does anyone have any suggestions? (Recompilation to 64-bit is unfortunately not an option).
I had the same problem with our 32-bit SNMP extension agent DLL which was solved by this way:
[HKEY_LOCAL_MACHINE\SOFTWARE\Wow6432Node\OTES\NL_CUTDA\CurrentVersion]
REG_EXPAND_SZ : "Pathname"="%ProgramFiles(x86)%\OTES\NL_CUTDA\NL_CUTDA.dll"
[HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Control\SNMP\Parameters\ExtensionAgents]
REG_SZ : "nl_cutdamib"="SOFTWARE\\OTES\\NL_CUTDA\\CurrentVersion"
I think you do not have to change path to the registry subtree because HKEY_LOCAL_MACHINE\Software key is redirected to physical path HKEY_LOCAL_MACHINE\Software\Wow6432Node by
Registry Redirector.
When I execute the command "iisreset" through an ssh terminal on a remote windows machine, I get the following error:
Attempting stop...
Restart attempt failed.
Access denied, you must be an administrator of the remote computer to use this
command. Either have your account added to the administrator local group of
the remote computer or to the domain administrator global group.
When I type whoami, it shows that I am the administrator. My cygwin ssh session is running as the "cyg_server" user who has admin privileges.
My ssh server is configured with privilege separation and allows me to login as administrator.
When I run the command locally, it works fine. The problem is execution through ssh.
I've also used process monitor to see what's going on, but it does not indicate the problem.
That is pretty strange because I am able to do admin-only operations in remote ssh such as:
echo "hi">/cygdrive/c/x.txt
rm /cygdrive/c/x.txt
Turning off UAC did not make a difference.
Any ideas?
I had a similar problem: unable to start/stop services using net start/net stop from a remote password-less (public/private key) SSH user. Attempting to start/stop the service was resulting in a "System Error 5 has occurred. Access is denied." error).
I had to install Cygwin's LSA authentication package (see http://cygwin.com/cygwin-ug-net/ntsec.html#ntsec-setuid-overview) in order for (I presume) setuid to work properly for password-less logins.
The problem should go away once LSA is installed on the Cygwin/SSH host and the machine has been rebooted.
I got scared of the LSA package mentioned in #user3609241's answer because of this sentence in the LSA docs:
as soon as the LSA encounters serious problems (for instance, one of
the protected LSA processes died), it triggers a system reboot.
But, those same docs point to a very easy way to "runas" SYSTEM - just use the at command:
$ date
Mon, Jan 12, 2015 8:17:35 PM
$ at 20:18 iisreset
Added a new job with job ID = 1
$ at
Status ID Day Time Command Line
-------------------------------------------------------------------------------
1 Today 8:18 PM iisreset
It works, at the cost of having to wait up to 59 seconds.
(wrapping the above sequence of commands in a simple-to-call script is left as an exercise to the reader; our management util is written in Perl so it was pretty straightforward).
Run the Cygwin terminal as administrator
Cannot start LocalDB instance, I have installed and re-installed over and over.
Keep getting this error :
Start of LocalDB instance "v11.0" failed because of the following error:
Error occurred during LocalDB instance startup: SQL Server process failed to start.
Anyone any advice ? ?
Microsoft SQL Server 2012, i have ensured the FULL installation options, stopped all services SQL related and tried restarting .
sqllocaldb info
gives me :
Projects
v11.0
when i try
sqllocaldb start v11.0
I get the above error.
When all else fails and you don't care about data loss, delete and recreate your LocalDB\v11.0 database! At the command prompt
sqllocaldb delete v11.0
sqllocaldb create v11.0
(Sqllocaldb is in your PATH right? It was for me.)
I was getting a similar error, but when running
sqllocaldb start
The local db started successfully. Also when checking the event log I saw an error along the lines of
Windows API call WaitForMultipleObjects returned error code: 575
What fixed it for me:
In IIS, configure the app pool to run under an account with permissions to the DB on the server (advanced options of the app pool)
In the advanced option of the app pool, set Load User Profile to true
Reference: http://blogs.msdn.com/b/sqlexpress/archive/2011/12/09/using-localdb-with-full-iis-part-1-user-profile.aspx
It worths looking at LocalDB log files too, it is more detailed than event log:
%LocalAppData%\Microsoft\Microsoft SQL Server Local DB\Instances\ProjectsV12\error.log
Besides recreating the instance I had to delete the content of this folder:
%LocalAppData%\Microsoft\VisualStudio\SSDT\
This is where I have the mdf and ldf files.
My solution:
Go to: %LocalAppData%\Microsoft\Microsoft SQL Server Local DB\ and allow total control of the folder "Instances" to everyone group.
I know this is not OK but it solved my problem and i don't really care about the data of that folder as this is a developing and testing computer.
Same problem here. Here's how I fixed it using bits of the other solutions posted here.
I had dozens of these errors in the application event log:
Windows API call WaitForMultipleObjects returned error code: 575. Windows system error message is: {Application Error}
The application was unable to start correctly (0x%lx). Click OK to close the application.
Reported at line: 3730.
I realized that I had SQL Server Management Studio installed on my development machine, but no other SQL components. I installed the database engine, shared components, and localdb from SQL Express
https://www.microsoft.com/en-us/cloud-platform/sql-server-editions-express
After installing, I still get the same error in event log :(
Found this article:
Cannot start LocalDB
Run the following in cmd to get the localdb instance name:
C:> sqllocaldb info
In my install, I had:
MSSQLLocalDB
ProjectsV13
I ran the following to delete the instances:
sqllocaldb delete MSSQLLocalDB
sqllocaldb delete ProjectsV13
I ran into issues trying to delete/create these (sqllocaldb delete MSSQLLocalDB). I ended up deleting all of the folders and files under '%LocalAppData%\Microsoft\Microsoft SQL Server Local DB\Instances*' (You need to stop SQL Server and kill all sqlserver processes)
Then running 'sqllocaldb create' created and started the default instance and all files.
Had this issue suddenly too but saw nothing weird in logs. Was able to get it running by running the following in an administrator command prompt:
sqllocaldb start
I had this issue. I was trying to use Windows Authentication through an application, but the IIS App Pool credentials were wrong. I was using my Windows user name (ie: NETWORK\name) as my identity, but I changed it to the built-in "LocalSystem" and it worked.
You should check the Event Log for additional information.
Product Name
SQL Server
Product Version
11.0
Product Build Number
Event ID
266
Event Source
SQL Server Local Database Runtime 11.0
Component
Local Database Runtime API
Message Text
Error occurred during Local Database instance startup: SQL Server
process failed to start.
Explanation
A SQL Server process is started but SQL Server startup failed.
User Action
See the event log for details.
Source: http://msdn.microsoft.com/en-us/library/hh256140.aspx
What worked for me was the local IIS application pool I was using was the ApplicationPoolIdentity and that did not have permission to login to MSSQLLocalDB. As soon as a I changed the app pool identity to my windows login account - I was able to connect ok.
Had this issue on Windows 10 when our application was run with compatibility for Windows 8 enabled. Turning off the compatibility setting fixed it.
Before you try something drastic:
After waiting for about 5 minutes it "healed" itself.
(May be this is what this log message is pointing at: "The RANU instance is terminating in response to its internal time out")
I can not yet comment posts here but I really want to give a hint for the in my case extremely helpful post https://stackoverflow.com/a/30298863/8015089 above:
If your LocalDB instance is run by the Windows SYSTEM user (as in my case) the path to error.log is this (MS SQL Server 2012 Express LocalDB on Win11): C:\Windows\System32\config\systemprofile\AppData\Local\Microsoft\Microsoft SQL Server Local DB\Instances\<InstanceName> (enter this path subfolder by subfolder to avoid access problems!)
I've written a script to search/download/install Windows Updates on a machine using the Microsoft.Update.Session COM Object. When run locally it works just fine, however when running through a remote session or through Invoke-Command I receive an access denied (0x80070005) error on Microsoft.Update.Session.CreateUpdateDownloader()
I receive the same error if I attempt to create a Downloader object directly, code to reproduce the issue:
$oUpdateDownloader = new-object -com "Microsoft.Update.Downloader"
I am an administrator on the remote machine, and passing credentials (for myself explicitly or any other admin account) to the machine does not seem to change anything.
I've seen this error posted a number of times but there does not seem to be any information on solving the problem...
Any ideas?
When you are in a remote PowerShell session your logon session on this remote computer is flagged as a "network" logon (Logon Type: 3).
For some obscure (security? sell SCCM?) reason, part of the Windows Update Agent COM APIs are restricted to only be usable by locally logged on Administrators.
Using PsExec and Scheduled Tasks have been suggested as workarounds.
IMO, the most seamless (and still secureable) solution is to facilitate the RunAs-style "Local Virtual Account" feature of PowerShell Session Configurations / JEA.
Usually, JEA is used to "restrict" what a user can do on a remote computer PowerShell-wise, but we are (ab-)using it here to gain full access as if we were a locally logged on Administrator.
(1.) Create a new unrestricted (and persistent!) session configuration on ComputerB (remote server):
New-PSSessionConfigurationFile -RunAsVirtualAccount -Path .\VirtualAccount.pssc
# Note this will restart the WinRM service:
Register-PSSessionConfiguration -Name 'VirtualAccount' [-ShowSecurityDescriptorUI] -Path .\VirtualAccount.pssc -Force
# Check the Permission property:
Get-PSSessionConfiguration -Name 'VirtualAccount'
# Those users will have full unrestricted access to the system!
(2.) From ComputerA (local client) connect to our unrestricted session configuration on ComputerB:
New-PSSession -ComputerName 'ComputerB' -ConfigurationName 'VirtualAccount' | Enter-PSSession
[ComputerB]: new-object -com "Microsoft.Update.Downloader" # Yay!
This is a known issue. It appears that there is a bug with the actual COM object itself, as this issue occurs when using VBScript, PowerShell, and even C#. There is a good article that discusses managing Windows Update with PowerShell that can be found here.
The workaround is to set up a scheduled task on the computer and you can invoke that task however you see fit.
Use PsExec (http://technet.microsoft.com/en-us/sysinternals/bb897553.aspx) to remotely execute PowerShell with a script file:
psexec -s \\remote-server-name C:\Windows\System32\WindowsPowerShell\v1.0\powershell.exe \\server\script.ps1
I used the script detailed at http://www.ehow.com/how_8724332_use-powershell-run-windows-updates.html, and I can remotely execute it using psexec to download and install updates.
the windows update code isn't callable form a remote machine. there are a few workarounds out on the web, including using psexec and a script (powershell or vbscript).
I used WUInstall myself and BoeProx has documented a few alternatives and has started a project PoshPAIG. I moved jobs before using this so don't know if it works.
The other solution is to change Windows registry setting using PowerShell and optionally restart wuauserv for the changes to take effect.
For example in Windows Server 2008R2 AutoUpdate settings can be found at:
HKLM:\SOFTWARE\Microsoft\Windows\CurrentVersion\WindowsUpdate\Auto Update