CouchDB Fauxton "Save failed: undefined" - couchdb-2.0

What could be causing this banner error 'Save failed: undefined' for v2.1.1 in Chrome 68 and Firefox 62 on Ubuntu?
With a fresh/recent login with admin permissions, suddenly (versus a few days ago with same system) I cannot create a new document in a custom database or the _users database, or edit any existing documents, or create a new database, but I can view all documents. Creating a database never gives the normal subsequent 'Database created successfully' banner.

Our server was out of storage space. Rule #1, save a backup before doing any remedying operation.

Related

Error: 18456, Severity: 14, State: 38 Reason: Failed to open the explicitly specified database 'ReportServer'. [CLIENT: <local machine>]

I'm facing a situation which every 10 seconds an error log is recorded with the following msg:
2018-07-25 09:07:09.59 Logon Error: 18456, Severity: 14, State: 38.
2018-07-25 09:07:09.59 Logon Login failed for user 'svc_sql'. Reason: Failed to open the explicitly specified database 'ReportServer'. [CLIENT: <local machine>]
In my instance I don't have a 'ReportServer' database. I know that in the past the server was migrated to a new machine and I reckon the 'ReportServer' database was created with a new name in the new server. I really don't know how the migration was done.
I've activated the SQL_Profiler with all audit options and I could see that this user also executes a procedure sometimes.
I've checked the default database for this user and it's Master.
Any ideas how can I fix this issue? My error log is flooding with this message.
Thanks a lot.
Rod
I've checked the default database for this user and it's Master.
The error doesn't tell you about default database but about explicitly specified database, that is different, it's the database that is mentioned in connection string under Initial Catalog or Database.
Do you see what application tries to open this database? The problem is in that application, it uses old connection string. If it's SSMS, it's simple, it's in the Options of connection dialog, but if it's another application, the connection string can be written in the ini file or hardcoded.
I don't know if I try to run DBCC CHECKDB master will solve this.
Of course it cannot solve this. This has nothing to do with database integrity. It's your client that uses wrong connection string.
Any ideas how can I fix this issue? My error log is flooding with this
message.
If you just want to save your errorlog from these messages just turn off failed logins audit:
Or you should find this application by its name or host or client address.
Or you can temporarily disable this login and see who will call you saying he cannot login anymore, or, if it's your local machine, some of your applications will fail, this way you'll find it.
I had the same error and doing the following resolved the error for me:
From within the SQL Server Management Studio
Security
Logins
Right Click the user ID that was failing login
Server Roles
Make sure all the checkboxes are checked. Right clicked Security and refresh.

RavenDB database restore: Operation failed: Cannot access file, the file is locked or in use

A year ago, when we started using RavenDB, we quickly hit this error in production:
Operation failed: Cannot access file, the file is locked or in use
We found out through some forums, that we could get rid of this by not running RavenDB as an IIS website, but as a service. We did, and never saw the error again.
Until now: I'm setting up a new environment and thought, I'd give it a whirl with running RavenDB off IIS, but the error quickly reappeared.
Facts and what I've tried:
running off v.30155 on a commercial license
using a custom AppPool (called RavenApplicationPool)
have data-folder separate from IIS dir (through Raven/WorkingDir AppSetting)
RavenApplicationPool user has "Full control" permissions on both IIS folder and data-folder
Windows Authentication installed and enabled for website
overlapped recycle disabled for app-pool
webdav-publishing not installed (as requested in setup docs)
hitting my keyboard (no luck)
The error occurs at random when site has been running for a few minutes. It also occurs when trying to restore a backup using the following command:
C:\RavenDBExecutables\Server\raven.Server.exe --restore-source=c:\SOME_PATH\my-db-backup.raven --restore-database-name=my-db --restore-database=http://localhost:8080
(the RavenDBExecutables folder is merely the zip of binaries/executables et.c. - it does not overlap with the IIS website folder)
When running the restore, these folders are created:
IndexDefinitions (contains a lot of files ending in .index)
Indexes (lot of folders with integer names)
logs (empty)
system (empty)
temp (empty)
root folder (my-db) is empty, i.e. no Data file, .resource.database or raven-data.ico as with working db's
After failed import, if I visit http://localhost:8080/docs/Raven/Restore/Status, I get
*a lot of lines like "Copying PATH_TO_INDEX_FILE", *
"Esent Restore: Failure! Could not restore database!",
"Microsoft.Isam.Esent.Interop.EsentFileAccessDeniedException: Cannot access file, the file is locked or in use\r\n at
Microsoft.Isam.Esent.Interop.Api.Check(Int32 err)\r\n at
Microsoft.Isam.Esent.Interop.Api.JetRestoreInstance(JET_INSTANCE
instance, String source, String destination, JET_PFNSTATUS
statusCallback)\r\n at
Raven.Database.Storage.Esent.Backup.RestoreOperation.Execute()",
"Unable to restore database Cannot access file, the file is locked or in use"
What can it be then?
The reason this happens is that IIS by default does overlapped recycle.
That means that both versions of the app are running (and both are trying to use the same resources).
With overlapped recycled set to false, that shouldn't happen.
We have seen similar errors when users have set two databases to the same path

What permissions/policies are needed to support loadUserProfile=true for new application pools?

Something happened on my development workstation (Windows 8.1) in the last few weeks which require me to either run my App Pools with the "Load User Profile" setting at False or not run with the identity set to ApplicationPoolIdentity. If I were to create a new app pool, using ApplicationPoolIdentity as the identity and with loadUserProfile=true, the following happens when trying to load the application in a browser:
A number of errors in the Windows Event Log (both System and Application types):
Warning event 1509 - Windows cannot copy file \\?\C:\Users\Default\AppData\Local\Microsoft\VSCommon\12.0\SQM\sqmdata-7236-039-00000.sqm to location \\?\C:\Users\[Name of App Pool]\AppData\Local\Microsoft\VSCommon\12.0\SQM\sqmdata-7236-039-00000.sqm. This error may be caused by network problems or insufficient security rights.
Error event 1511 - 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.
Another 1509 warning
Error event 1500 - Windows cannot log you on because your profile cannot be loaded. Check that you are connected to the network, and that your network is functioning correctly. DETAIL - Only part of a ReadProcessMemory or WriteProcessMemory request was completed.
5 x event 5022 warnings - The Windows Process Activation Service failed to create a worker process for the application pool '[App Pool Name]'. The data field contains the error number.
Finally an error 5002 - Application pool '[App Pool Name]' is being automatically disabled due to a series of failures in the process(es) serving that application pool.
The App Pool is shut down, as the error 5002 said
"HTTP Error 503. The service is unavailable." is then seen in the browser. Any further requests are met with the same (which makes sense since the app pool is shut off).
I've seen a common "fix" for this here and here which basically say to turn off profile loading. Yes it makes the problem go away, but this doesn't get to the root cause. I know that it is possible to run with this configuration as a I have a Windows 2012 machine which supports the configuration just fine. In this case, hitting an app with a new app pool set to ApplicationPoolIdentity and loadUserProfile=true actually creates the new user profile (I can watch as the profiles folder is created in C:\Users) and the app runs merrily. What's worse is I know this configuration worked on the problem machine just a few weeks ago. I have a number of App Pools I created which have their own profiles and folder under the C:\Users folder. These app pools work just fine NOW with the ApplicationPoolIdentity and loadUserProfile=true settings. It's just that NEW app pools refuse to run and load a user profile.
Does anyone have any insight to what might be going on?
Edit: I read the bottom of this recent article. It's a bit contradictory in saying that the setting can be turned on, but also says:
Only the standard application pools (DefaultAppPool and Classic .NET AppPool) have user profiles on disk. No user profile is created if the Administrator creates a new application pool.
However, if you want, you can configure IIS application pools to load the user profile by setting the LoadUserProfile attribute to "true".
I'm very confused.
The SQM file listed in the event log warning was created by a Windows or Visual Studio update. When the user profile service or application pool runs and tries to create a new profile, it tries to copy the file to the profile. The SQM file requires administrator permissions to copy. The user profile service or application pool does not have sufficient permissions to copy the file, an error is generated, and the user profile is not created. Without a user profile, the application pool cannot run because it doesn't have an isolated secure place to store data.
Remove or delete the SQM file from the source directory, and the user profile will be created successfully when the app pool is initialized. You can also change the permissions on the SQM file, but I'm not sure what the appropriate permissions should be. The user profile service runs as "LocalSystem Account". See its documentation for permission info. It's unclear to me whether the application pool identity itself is being used to perform the copy operation, or the local system account.
If you remove the file from the source directory, you could also manually copy the file where it was trying to go as well.
After a very brief search about what SQM is, it seems like it is traditionally used as "service quality management". Usually it would contain information to send back to the program authors with metrics, logs, or somesuch. I don't know if this is the case with this file or not. So it doesn't seem like it's important to include it in the new profile.
I can't take 100% credit for this answer, as I was tipped off by a comment attached to an answer on some other question. I can't find the link to it in the 50 browser tabs open for troubleshooting this. That guy deserves a thank you, because I believe this is a much better solution than compromising the security of a server by pooling all the resources together like in IIS 6.
P.S. As noted in your comment, a bug report has been filed.

Issue with data sources that are created through the Pentaho Admin Console

Issue with data sources that are created through the Pentaho Admin Console ,Now my MySQL IP has been changes, i did modification in my BI server .
But Pentaho Admin console in not up .!
From logs i found this is having
01:24:40,370 ERROR [Logger] misc-org.pentaho.platform.engine.services.connection.datasource.dbcp.PooledDatasourceSystemListener: PooledDatasourceSystemListener.ERROR_0003 - Unable to pool datasource object: MyLocalDatabase caused by com.mysql.jdbc.exceptions.jdbc4.CommunicationsException: Communications link failure
The last packet sent successfully to the server was 0 milliseconds ago. The driver has not received any packets from the server.
01:24:40,857 WARN [PersistenceEngine] Falling back to built-in config
This MyLocalDatabase database Created at Pentaho Admin Console has to be changed with new IP . Do any one help me to know , which file consists of datasources that are created through the Pentaho Admin Console
My PAC is down, no error in server.log file
Datasource information is kept in the hibernate database.
By default, this is kept in an hypersonic database that is launched when you start the BI server. Check context.xml in webapps/pentaho/META-INF to make sure.
There's a DATASOURCE table in there that stores the data source definitions.

MVC 4 - how to change default SQL Server Express database location

In VS 2012 I created a new MVC 4 project starting from the internet application template, then changed its properties to use SQL Server Express instead of LocalDB, then tried successfully to register a new user.
First, the project created its own membership database in the App_data folder, but for deployment reasons I wanted to change the database location, so I moved the database physical files from C:\MyProject\App_Data\ to C:\MyData and modified the related path in the web.config file. To ensure that the database is reachable by the SQL Server Express instance, I added my own user account with full access in the properties security tab, then successfully shown its data in SQL Server Management Studio.
Now, when I run the project, and click on the "log in" link, the debugger stops at LazyInitializer.EnsureInitialized and fails with an error; the inner exception of the error message says:
Database
'C:\MyProject\App_Data\aspnet-MyProject-20121206123456.mdf' already
exists. Choose a different database name.
Cannot attach the file 'C:\MyData\aspnet-MyProject-20121206123456.mdf' as database
'aspnet-MyProject-20121206123456.mdf'
I checked all the project to find any different database connection settings but found nothing.
Within VS, when I use the server explorer to view the database tables data, I cannot find "show data" option when I right click on one of the displayed tables, when I go to C:\MyData\ folder to see the physical database files properties, in the security tab, I find that each time I run the project my account using full access was removed.
Also the browser is displaying the next Exception text:
The data provider. Net Framework requested was not found. It may not be installed.
C:\MyProject\Filters\InitializeSimpleMembershipAttribute.cs Ligne : 42
Ligne 40 : }
Ligne 41 :
Ligne 42 : WebSecurity.InitializeDatabaseConnection("DefaultConnection", "UserProfile", "UserId", "UserName", autoCreateTables: true);
Ligne 43 : }
Ligne 44 : catch (Exception ex)
It looks like a Visual Studio 2012 bug which doesn't recognize SQL Server 2012 Express instance. I have downloaded Microsoft WebMatrix2 and used it to load the website and could successfully log in using the moved membership database.
With this bug I've lost 2 days trying to find a solution.