Dropbox As A Service

Dropbox, what a great service. Mobile support, multiple OS support (Linux, Windows, Mac), unlimited previous versions, LAN sync to save internet bandwidth. Pretty much everything, but what if I’ve got a server that I want to leave logged in, or can’t. Well Dropbox you’ve let me down in a big area now, or have you?

I was researching the net for a solution to make Dropbox top run as a service and I found a solution it was just broken up at a couple of places, so I’ve decided to put the answer in one location, and put my system administrator stamp of approval that this process is save to do on windows server 2003 & 2008 and there is a good change 2012 too.

So here is what to do to run Dropbox as a service.

First you will need to install a Microsoft resource kit which is available from the below link. It does state that it’s for Server 2003 and some of the resource kit is incompatible with 2008 but installing it into Program Files isn’t going to upset your server and this process we are going to use does work.

http://www.microsoft.com/downloads/details.aspx?FamilyID=9D467A69-57FF-4AE7-96EE-B18C4790CFFD&displaylang=en

The below link is where I received the below part of this guide. I’ll give them the credit, I just felt that I could reword it to make it easier to follow.
http://blog.dreamfactory.se/2011/01/20/dropbox-as-a-service/
I wanted to install a backup solution, and made a go for using the Dropbox service

1. Install Dropbox, if not installed previously and connect it to your Dropbox account and get the client working as you want with the folders you wish you to synchronize.
2. Go into / or while your in preferences and uncheck “Show desktop notifications” and “Start Dropbox on system startup”
3. Right click the DropBox icon in the bottom right next to the clock and select Exit. It is important to make sure to program is closed.
4. Press the Start button and in the search field type “cmd”. At the top of the start menu, right click command prompt and click Run As Administrator.
5. Now type the below into the black box.
CD C:\Program Files (x86)\Windows Resource Kits
instsrv Dropbox "c:\Program Files (x86)\Windows Resource Kits\Tools\srvany.exe"

You should receive a “The service was successfuly added”

Make sure that you go into the Control Panel and use
the Services applet to change the Account Name and
Password that this newly installed service will use
for its Security Context.

Next is to change the user for witch the newly added service “Dropbox” runs under. Change this to Administrator.
5. Choose properties on Dropbox service.
6. Click on tab “Log On”
7. Click “This account”, and select Admimistrator. Set appropriate password.
8. Click Apply and OK

If this is the first time you have done this procedure for the administrator user, you will get an notification saying that the “Administrator user has been granted log on as service rights”

Next is to setup some registry settings for the service
9. Start > Run > regedit
10. Navigate to HKEY_LOCAL_MACHINE\SYSTEM\CurrentControlSet\Services\Dropbox
11. Create a new key “Parameters”
12. Add a new string value “Application”, (type REG_SZ). Set the value to the path to the dropbox.exe binary. Find the location by right clicking on the Dropbox icon on the desktop. Simply copy the path from there.
13. Close Registry Editor
14. Go back to Services, and start the Dropbox service

Now everything should be in place and work correctly.

Addition: It works fine to stop the Dropbox service, then start Dropbox and make changes in preferences etc, save changes and exit Dropbox. Then you can start Dropbox service again without problems. Work very neat actually. Running now on Windows Server 2003 and Windows Server 2008 64-bit. On Windows Server 2008 you can just copy instsrv.exe and srvany.exe to a folder under Program Files and create the Dropbox service from there.

Certificate Request Processor: The system cannot find the file specified

What does this error mean?

c:\Users\Administrator\Documents>certreq.exe -submit -attrib "CertificateTemplate:WebServer" certreq.req
Active Directory Enrollment Policy
{9C38F712-49F4-45FB-AD5E-F44BFE9BAB92}
ldap:
Certificate Request Processor: The system cannot find the file specified. 0x80070002 (WIN32: 2)

It means the Active Directory Certificate Services role isn’t installed. Install that and your problem will go away.
ADCertificateServicesRole

Cisco Dynamic Name Update

In an enabled user and configure terminal mode enter the below edited details.

ip ddns update method dyndns
HTTP
add http://username:pa55w0rd@members.dyndns.org/nic/update?system=dyndns&hostname=<h>&myip=<a>
interval maximum 28 0 0 0
!
interface Dialer0
ip ddns update hostname hostname.dyndns.org
ip ddns update dyndns

To enter a question mark you must type ctrl-v before pressing ?

Use “debug ip ddns update” to check the result.

wp-admin access problems after database table change

So I’ve moved a WordPress site from one hosting provider to the next, and I didn’t like the naming of the database tables.  So I renamed the tables to something more preferred but then I received the below error message after successfully logging into the admin area.

You do not have sufficient permissions to access this page error

The website itself works perfectly right, it’s just the admin section.  Now the whole reason for me posting this is there is heaps and heaps of information about how to solve this problem but because WordPress is written for anybody to easily use, the answer was hidden by lots of people saying the same thing, that and, mentioning database upgrades that had gone wrong.  But in this case that wasn’t the problem.

The resolution, there are some table fields that make reference to the table names some how so when changing the database tables you need to change the below entries too.

You will need to use phpMyAdmin, it’s normally installed with cpanel, but if its not its really easy to install, just make sure you secure it as many people attempt to hack it.  Hopefully with out getting to technical, we will imagine our orginal tables had a prefix of wp_ and we’ve change them to wp_blog.  Add your names as such below.

table , wp_options which would now be wp_blogoptions
– option_name , wp_user_roles change to wp_bloguser_roles
table , wp_user_meta which would now be wp_bloguser_meta
meta_key , wp_capabilities change to wp_blogcapabilities
meta_key , wp_user_level change to wp_bloguser_level
meta_key , wp_dashboard_quick_press_last_post_id change to wp_blogdashboard_quick_press_last_post_id
meta_key , wp_user-settings change to wp_bloguser-settings
meta_key , wp_user-settings-time change to wp_bloguser-settings-time

Now you’ll need to make these usermeta changes for every user on your site, hopefully you don’t have too many.

I hope this is a help as it too me a couple of night to fully understand what was going on.  Happy blogging 🙂