Difference between revisions of "Quickbooks Database Server Manager"

From Steak Wiki
Jump to navigationJump to search
Line 144: Line 144:
  
 
* https://community.spiceworks.com/topic/2215961-installing-quickbooks-database-manager-on-centos-7 - A post on spiceworks, where the user essentially says, "Contacted support, who talked to engineers, and they said basically, 'uh, Linux doesn't really work at all. Sorry.'"
 
* https://community.spiceworks.com/topic/2215961-installing-quickbooks-database-manager-on-centos-7 - A post on spiceworks, where the user essentially says, "Contacted support, who talked to engineers, and they said basically, 'uh, Linux doesn't really work at all. Sorry.'"
 +
 +
 +
* https://forums.unraid.net/topic/70873-quickbooks-database-server-manager/ - Extensive discussion on unraid's forums here (unraid which I see shilled a bit, and is proprietary)
  
 
==Conclusion==
 
==Conclusion==

Revision as of 17:20, 27 August 2020

Caution: This page discusses Proprietary Software which is known to do the following to computer users: Record their actions, Mine their personal data, Steal business secrets, and other nefarious things. Steakwiki recommends against using unknown and unvetted software whenever possible.


Quickbooks Database Server Manager by Intuit, supposedly also runs on GNU\Linux. I've spent some 10-20 hours trying to get it to work and here's what I know. This program supports QB Enterprise clients only (I have read). After all the time and trouble, I've been given by Intuit, I ended up finding that QB on Linux (2014) only works with a single user. It does NOT work with multiple users, and generally does NOT work at all. Don't bother using QB with Linux, unless you want a bad time.

Overview

What QB Database server manager for Unix is, is Sybase SQL Anywhere. It appears to be tailored to Quickbooks. There are two programs:

  • qbfilemonitord
  • qbdbmgr_##

The number refers to your edition of QB. 2014, uses QBDBMGR_24.

The program is offered in an RPM format. It is possible to convert the RPM to a .DEB and install it on Debian. However there are integrated commands that will fail (a ps -efff which searches the task list for the port and ip of qbdbmgr), so its best run in RHEL. The program is a pair of 32 bit binaries, so it's either run in 32 bit or you can install 32-bit compatibility libraries in 64-bit mode.

The RPM will unpack two main directories. in /opt it will put two folders for the binaries. In /etc, it will put an init.d script, and a logrotate.d script. There are also configuration files in /opt/. Additionally, the .qbw.TLD, .qbw.DSN, .qbw.ND files contain paths relevant to the QB DB manager (in plain text for the latter two). However, you can delete them before the first run of the .qbw file, and the server will generate them. Do not delete them while the DB is being accessed or you can crash QB. There is a qbdir.dat file that the db server will generate as well, that also has path info.

Install Steps

This will get its own article, as its a bit of steps -> Installing Quickbooks Database Server Manager on Linux. Essentially, I have tested Centos 7. You will need samba installed, SELinux either off, or configured, and iptables addressed along with users. This is all easy.

How to resolve H202 Error in Quickbooks Database Server with Linux

Per the Quickbooks FAQ page on this, adding a hard coded hostname for the ip address of the DB server should eliminate this error. It goes in the hosts file of Windows (C:\Windows\System32\drivers\etc\hosts).

If you manage to crash a running session of the DB, you can also see this error. In that case, restarting should resolve it.

It is also possible to see this error if the QBDBMGR services aren't running on the server.

How to resolve the "QBDB_ARGUMENT_ERROR: FixNDAndPermissions request sent to Linux" Error

Not sure yet. It seems that it can be ignored.

What others have done

The most helpful links are: https://www.nivindel.com/installing-quickbooks-enterprise-linux-server/ This one is good, but the information about the QBW.ext files is not important. The Linux box will generate them. Best advice is to only copy over the QBW (but no other files) from the main server, so that any old info isn't carried over. Finally, if you have old TLD, or ND, or DSN files, it will take 2x longer to load the first time.

https://dave.umry.sh/posts/quickbooks_linux/ From what I can tell, he didn't test enough. Although the instructions for setup are good. It's easy to open a DB file in single user mode, but a functioning multi user mode is what we are after. Actually, if you want to run QB DB Server in single user mode, it's easy in GNU\Linux. Multi user is where things start getting ugly.

Programs

QBDBMGR_##

/opt/qbes14/SYBSsa11/bin/QBDBMgrN_24

This is the Sybase SQL Anywhere program. This can be run in the foreground, but there are a number of flags that can be used to adjust it. Lots. This makes running it from the shell non-trivial. See /etc/init.d/ startup script for more details.

qbmonitord

/opt/qb/util/qbmonitord

This program can be run in the foreground and has additional verbosity available beyond the logs. There is an /opt/qb/util/qbmonitord.conf that contains the path of the QB workbook (requires editing). This can be run with a -h or --help flag to get options.

Foreground Debugging

Run it with -f to see foreground debugging. (found via ./qbmonitord -v)

user@(none):/opt/qb/util$ ./qbmonitord -f
***** qbmonitord version 2.0 is starting up *****
Running in the foreground
Created new Tcp Listener
tcplistener starting
QBDBPF Server now listening..
QBDBPortFinder Started successfully!!
***** qbmonitord initializing *****
Reading config file "/opt/qb/util/./qbmonitord.conf"
tcplistener thread has started
Monitoring directory "/opt/qb/util/./"
Monitoring directory "/QBData/"
"/QBData/qbdir.dat": Creating meta file
"/QBData/qbdir.dat": --- Creating meta file
--- ERROR CREATING META FILE. Error=Permission denied
Error creating meta files.
***** qbmonitord daemon has started monitoring *****
To halt program, type ctrl-C.
*** Event Output ***

Logging

See /var/log/messages in Centos, or run the programs in the foreground.

Working Exchange between DB and Client workstation

It appears possibly the FixNDAndPermissions error can be ignored.

[root@qbtestsrv user1]# tail -F /var/log/messages
Dec 10 22:05:01 qbtestsrv journal: qbmonitord daemon[1373]: Response sent from QBDBPF server
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: Accept is successful! Client connection accepted
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: Message received at server.
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: GetServerPort request received at QBDBPF server
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: Found the port 55358 in root      1369     1  1 21:42 ?        00:00:22 /opt/qbes20/SYBSs$
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: Response sent from QBDBPF server
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: Accept is successful! Client connection accepted
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: Message received at server.
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: QBDB_ARGUMENT_ERROR: FixNDAndPermissions request sent to Linux
Dec 10 22:05:10 qbtestsrv journal: qbmonitord daemon[1373]: Response sent from QBDBPF server
Dec 10 22:07:09 qbtestsrv journal: qbmonitord daemon[1373]: Accept is successful! Client connection accepted
Dec 10 22:07:09 qbtestsrv journal: qbmonitord daemon[1373]: Message received at server.
Dec 10 22:07:09 qbtestsrv journal: qbmonitord daemon[1373]: GetServerPort request received at QBDBPF server
Dec 10 22:07:09 qbtestsrv journal: qbmonitord daemon[1373]: Found the port 55358 in root      1369     1  1 21:42 ?        00:00:24 /opt/qbes20/SYBSs$
Dec 10 22:07:09 qbtestsrv journal: qbmonitord daemon[1373]: Response sent from QBDBPF server

Example of an (almost) functioning QB DB Server on Centos 7 with QBDBMGR 24

Dec 10 22:34:30 qbtestsrv journal: qbmonitord daemon[1373]: Response sent from QBDBPF server
Dec 10 22:34:32 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): Starting database "b41d52cd3d3b480e88bc715443ab91e8" (/share/quickbooks/testco4.qbw) at Tue D$
Dec 10 22:34:33 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): Transaction log: testco4.qbw.TLG
Dec 10 22:34:33 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): Starting checkpoint of "b41d52cd3d3b480e88bc715443ab91e8" (testco4.qbw) at Tue Dec 10 2019 22$
Dec 10 22:34:33 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): Finished checkpoint of "b41d52cd3d3b480e88bc715443ab91e8" (testco4.qbw) at Tue Dec 10 2019 22$
Dec 10 22:34:33 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): Database "b41d52cd3d3b480e88bc715443ab91e8" (testco4.qbw) started at Tue Dec 10 2019 22:34
Dec 10 22:34:33 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): LIN: Login for 41646d696e on connId 21
Dec 10 22:34:33 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): CON: Connect for 41646d696e
Dec 10 22:34:33 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): LIN: Login for 41646d696e on connId 22
Dec 10 22:34:33 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): LIN: Users logged in: 0, effective file mode: 2 (SU=0, MU, NoMode)
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): LIN: Started conn pool with file mode: 1 (SU=0, MU, NoMode)
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): CON: Connect for 41646d696e
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): DIS: Disconnect for 41646d696e
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): DIS: Disconnect for 41646d696e
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): DIS: Cleanup for 41646d696e (0/0/1)
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): DIS: Recovery data updated
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): Starting checkpoint of "b41d52cd3d3b480e88bc715443ab91e8" (testco4.qbw) at Tue Dec 10 2019 22$
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): Finished checkpoint of "b41d52cd3d3b480e88bc715443ab91e8" (testco4.qbw) at Tue Dec 10 2019 22$
Dec 10 22:34:34 qbtestsrv SQLAnywhere(qb_qbtestsrv_24): Database "b41d52cd3d3b480e88bc715443ab91e8" (testco4.qbw) stopped at Tue Dec 10 2019 22:34

The error at this junction is: One user can login in multi user mode. Try to have a second user in, and it says on Win desktop #2

"quickbooks unable to open file, another user is opening it..."

Error code: -6000, -816 https://quickbooks.intuit.com/learn-support/en-us/open-programs/resolve-error-6000-when-opening-a-company-file/00/200822 This page does not address error 6000, 816. I have a mystery error...

Tips/Tricks

Using Sybase tools to discover QB databases

Yes, it is possible to use Sybase tools to discover QB DBs hosted by GNU\Linux on the LAN. You should also technically be able to connect, though I'm not sure what QB uses for credentials.

e.g. Sybase Central 6, has a Connect with Sql Anywhere 12 option.

Can you use a more recent QBDBMGR with older QB?

No. Even if you fool some of the scripts (init.d) into thinking it is the same Database version required by your QB, there are additional checks that will get you. It's best to use the one supported for your QB. Intuit deleted some off their website recently, so possibly support can provide them. That would be called built in obsolescence.

Why not use Docker to install QB DB Manager?

Good idea, but I didn't have any luck down this path. I need to try again. You would want to use Centos 32 bit.

Will Wine work with the Win DB manager?

Who knows? Another path to try.

Can I use Debian? It used to work...

No. The server is hard coded with ps -efff which is not valid in Debian. Apparently older QB DB Server manager used to support Debian per their user guides, but the more recent ones do not.

Further Info


Conclusion

As of 2020, this page is the most thorough delve into Quickbooks Database server on Linux support, I've seen, and it's a dead end. I contacted support, and they did what they have done to everyone else. The techs don't have any idea how it works, and are clueless. It's too niche. Don't waste your time with this one. It's a dead end. Quickbooks on Linux does NOT work, in my experience. Do not bother trying to run the DB server.

Hopefully this will save someone else from making this mistake.