windows server 2016. New users - "we can't sign into your account" - windows-server-2016

Windows server 2016.
Old users (those, having profiles/folders created at "C:\Users") are able to remote into our server via RDP, but new users are not. Initially the error was The User Profile Service service failed the sign-in. User profile cannot be laoded.
Checking server, it seems "C:\Users\Default" has the only folder/entry "AppData", nothing more. I copied the file "NTUSER.DAT" from similar server "Default" folder. Also, folder permissions are identical.
Now new users are able to login, but it goes to a temporary profile and of course, user's profile at "C:\Users" does not get created.
Event logs does not tell much, basically just confirms login errors/notes we get:
Windows cannot find the local profile and is logging you on with a temporary profile. Changes you make to this profile will be lost when you log off.
Windows has backed up this user profile. Windows will automatically try to use the backup profile the next time this user logs on.
How this can be solved?

Open the registry editor and go to HKLM\SOFTWARE\Microsoft\Windows NT\CurrentVersion\ProfileList then find the key where the ProfileImagePath is the profile location of the user that's not being created. Export, then delete that registry key.

Related

Can't Login to asp.net site on IIS

I've been fighting with this all day looking for solutions, and I've come to a dead end. As soon as I put my application on IIS, I've been getting login errors. One of the errors that I fixed was similar to this one which said " Cannot open database "ClientInfo" requested by the login.
Now I'm getting this error, which is the same, but I'm not sure how to modify the permissions of the NT AUTHORITY\NETWORK SERVICE user for this particular DB.
Cannot open database "aspnet-ClientInfo-20140609140222" requested by the login. The login failed.
Login failed for user 'NT AUTHORITY\NETWORK SERVICE'.
The full error message is here: s11.postimg.org/3x1vj1ezl/Untitled.png
don't worry too much. This is always a headache when it doesn't work the way you expect. Before I get started, please note that Network Service is probably too high of privilege level for any web app. Check out this article to see how to add a corresponding app pool for a specific website to your SQL Server logins: Add IIS 7 AppPool Identities as SQL Server Logons
This is the way I've solved these types of problems:
1.) Make sure you have access to SQL Server Management Studio Express, and log into the database server. If you are running on SQLEXPRESS, set the server name as .\SQLEXPRESS, or whatever your instance name is.
2.) Go to the Security folder at the server level. Right click on "Logins" and select "New Login". To the right of the Login Name text box, select "Search", then "Advanced", then "Find Now" (without entering any search criteria). Scroll down and select "Network Service"
3.) Hit Ok. Then hit OK again. Your new login has been added for your network service.
4.) Go to the Security folder at the database level. Add a new user by right clicking the User folder under security at the database level. Click the 3 dots (ellipsis) next to the login name, and then click "Browse". Select the checkbox next to the login name you created in step 2. Hit ok. Then hit OK again.
5.) The last part is giving your new user a user name (first text box at the top) and then mapping that user to the right privileges. I'm sure some folks that know more than I do will shoot me, but I always select db_datareader and db_datawriter under "Database Role Membership". If you're using the ASP_NET membership schemas, you should select all the basic access roles as well.
6.) Hit Ok.
Depending on the version of SQL server you're using, you may need see a mild fluctuation between my steps above and what you actually need to do. This should get you close, though.

Cannot open database "name" requested by the login

I am in process of moving Website and its database on a new server under IIS. I moved and attached the database on the new server. Added web site under the IIS, created App pool and made all the changes to the config file to connect to new data source and updated the root folders path.
The index page loads up fine. When i click on another page link, that communicates with the database and I get an error message that reads "Cannot open database "Cdb_name" requested by the login. The login failed. Login failed for user 'db_user'.
I have tried several steps but none seems to work. I am not sure if this is a right place to post this question. Any suggestions/help will be greatly appreciated.
Can you login to sql server using same user name or password. The problem is most likely:
User name / password is wrong
User don't have rights to access to that database
When you move a login from one SQL Server to a different server, it will not work unless it is a domain account. Delete the user from the Database; Security section, then add it back via the Security section. Liek this:
Delete here:
And add the user and User Mapping to the database here:

Sonatype nexus admin login

I'm having a problem which I can't solve.
I have bought a cheap vps, with ubuntu 12.10 then installed the tomcat7, maven, and nexus. All of them are the latest. This is a fresh install from everything. I started and deployed the nexus, no errors in catalina, no errors in nexus, and when I tried to login with admin/admin123, I have failed.
I'll show you any of my log file what you need, please help me with this.
EDIT: nexus is 2.2-01
EDIT2: this is a cheap server with 512 ram, running without X
My security-configuration.xml is this:
<?xml version="1.0"?>
<security-configuration>
<version>2.0.3</version>
<enabled>true</enabled><!-- was true -->
<anonymousAccessEnabled>true</anonymousAccessEnabled>
<anonymousUsername>anonymous</anonymousUsername>
<anonymousPassword>{1FH7iFzhCukHI3ISkjq+AuQZb+bOMrB70bGqF2y6fNE=}</anonymousPassword>
<realms>
<realm>XmlAuthenticatingRealm</realm>
<realm>XmlAuthorizingRealm</realm>
</realms>
<securityManager>default</securityManager>
</security-configuration>
Do the following:
stop Nexus
change the enabled in the xml to false
restart Nexus
get in without anything as admin that way
reset the admin password
enable the security again in the user interface
Oh and btw. I would suggest to run Nexus from the bundle with Jetty on a VPS and not with the war file in Tomcat so you get more performance out of it.
Update: Security can no longer be disabled in Nexus 2.7 and up. You have to insert an admin user into the xml as documented in this support page.
Resting nexus admin password from default "admin123" to more secured password without changing config files.
I got my nexus instance up and running with no issues login in as admin user and default password. I wanted to reset admin password ( to more secure password) and followed the following instructions (without touching the security.xml file as i hate changing config files to do any password resets)
Login to nexus with admin user and default password.
Click on server link under administration tab.
Make sure that SMTP settings are set up correctly ( hostname , port
, username and passowrd).
Click on "Test SMTP settings" and provide an email address to see if
you get mail from nexus server.
If you have already set up SMTP correctly on your instance you don't
need to run step 3 and 4.
Hit "Users" link under Security tab and select admin user. make sure
you have set up the correct email for this user.
Log out of nexus .
Login and hit forgot your "password" link.
The password recovery screen will prompt you for user which is
"admin" and email should be the one you have listed in step 6.
Hit "Reset Password" button and you ll get a much stronger password
in email .
Again Checking SMTP settings and admin user's email is one time action. Step 8 to 10 take less than a minute and one can easily reset admin password without touching the security.xml file. Ofcourse this file will be automatically updated as soon as you login with new password. Preferred way than modifying the file manually.

forcefully log out a specific user among all online users

In my site administrator can view list all other online users.
Administrator can also disable any account from that list.
Everything was going fine so far. But now I decided to log out the user which is being disabled. How can I do a log out operation for a particular user from the above specified online user list?
NOTE: I'm using default membership schema for my SQL Server database.
You cannot logout a user from outside of their session. See Programatically logout an ASP.NET user for a possible workaround.

Wordpress: Upgrade a user to admin without using the administration function or database access

I locked myself out of my Admin account on a client's site. I don't have access to the database because my client doesn't like to give that away, I need to upgrade my user account back into being an administrator. I've done it before, with something like wp_update_user() but I don't remember how & I can't find the online resource I used.
How can I upgrade my user account from being a user to being an administrator without knowing the ID of my account?
Thanks!

Resources