I am currently trying to replicate a SQL Mobile 2005 database with a SQL Server 2005 database through web synchronization using SSL Server AND Client Certificates. On IIS, with "Require Client Certificates" unchecked, I can replicate fine. Once I turn it on, I get a message from replication saying "A Secure Socket Layer connection is required to access this site". I have installed a client certificate in IE, and can access the https://servername/Ojt/sqlcesa30.dll site (I tried removing the client certificate, and I was denied access, then reinstalled it and it worked - so I think that part is working). Does anyone have any experience with this? My production operating environment requires client-side certificates.
Need to replicate mobile device that uses a wildcard certificate. Heard that ms windows mobile 5.0 does not support wildcard certificates. Is there a solution around this using vb.net.
I don't understand why I am having this error. It does create the database on AddSubscription() method but it is failing opening the database on Synchronise(). I have also tried uninstalling and then reinstalling all the SQL Mobile components in the following order.
suggested that this problem could be circumvented by getting the replication object early and then continuously using the same object for subsequent replications.
I did this and it works a lot better now but ever so often I get another error which is
Native Error 28559 SQL Mobile encountered problems when opening the database
My only option at this point is to stop and start the application which cures the problem.
Detection of product '{8670F53C-8AD7-4F34-BDBA-17B38A18CB65}', feature 'SQL_SSMSEE' failed during request for component '{6EC5DFBD-F6B5-4F02-8432-BFB8B03562B8}'
Error Description for Event ID - 1004:
Detection of product '{8670F53C-8AD7-4F34-BDBA-17B38A18CB65}', feature 'SQL_SSMSEE', component '{180F515D-F56C-40DD-9D71-CC532EA8E286}' failed. The resource '' does not exist.
While opening our SAP Mobile Client Application, in the task manager MSIEXEC.EXE is running and trying to repair the application and this will cause our application to take time to lauch. In the Event viewer, whenever we try to lauch our application we are getting this event id's. Can you please kindly provide a solution for this msg.
I want to manually install the database for the reference implementation (I have SQL 2005 Express when I installed the Factory, but AdventureWorksMobileStaging database is not installed in my sqlExpress, so i try to install manually in that database ) I have noticed a number of scripts under the AdventureWorksToGoDBScripts folder. Is there any specific order of installing those scripts?Any other things that need to be followed for getting the reference database up and running?Thanks in advance Varisai
Server 1: Windows 2003 inc IIS. Also on this server is SQL Server Web sync web service and it has an external IP address for internet connectivity
Server 2: Windows 2003 inc SQL Server 2005. This server has a database setup with replication so the a Window Mobile 5 device can do a merge replication.
My problem is that the replication fails when trying to send the snap shot from Server 2 to the mobile device. The device seems to get through to the replication agent, as entries in the Replication monitor are logged (see below).
I have checked all the permissions on the relevant shares required for replication (basically set "Everyone" with full access).
My initial question would be.... When the snapshot is been sent to the mobile device, does the SQL Server try to send it directly to the internet or does it go through "SQL Server Mobile Server Agent 3.0".
Please can someone help, as this is causing me some REAL problems.
Error messages: The schema script '\ukrt1-sql902SQLRepluncUKRT1-SQL902_EXEL_DAMAGECODESEXEL20060810142533DamageAction_2.sch' could not be propagated to the subscriber. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147023570) Get help: http://help/MSSQL_REPL-2147023570
The merge process was unable to deliver the snapshot to the Subscriber. If using Web synchronization, the merge process may have been unable to create or write to the message file. When troubleshooting, restart the synchronization with verbose history logging and specify an output file to which to write. (Source: MSSQL_REPL, Error number: MSSQL_REPL-2147201001) Get help: http://help/MSSQL_REPL-2147201001
Task : connecting the central system and remote system (PocketPC) and allowing merged replication as
Following are the steps that I used to perform a replication.
1 > I am trying to Publish a Data base articled for a SQL mobile subscriber.
2 > I follow the steps in the SQL Server 2005 Mobile Edition Books Online : Creating a Mobile Application with SQL Server Mobile .
3 > At the publishing time it successfully completes all the tasks. Below is the report
Creating Publication
- Creating Publication 'SQL Mobile' (Success)
SQL Server created publication 'SQL Mobile'.
- Adding article 2 of 2 (Success) Article 'FlightData' was added. Article 'MembershipData' was added.
- Starting the Snapshot Agent (Success)
4 > After the publication, When I check the Snapshot Agent Status, It has stopped. (p.s. when pressed start it says starting for about few seconds and drops ) and gives an error as below Executed as user: MAINsnapshot_agent. The replication agent encountered a failure. See the previous job step history message or Replication Monitor for more information. The step failed.
* As mentioned I checked the error log it says "encountered a non-logged user" but the user is logged on from another PC to the domain
5 > If I create a publication using SQL Server Agent service without specifying a user then it works.
This customer has an SFA application. They are using NET CF 2.0 SP2, SQL Mobile and Merge Replication with SQL Server 2005. The device they are using are Symbol MC7094. It has integrated phone and is a Windows Mobile 5 Aku 3.
They have set up 5 differents publications for this applications. His business case makes them to have 1 publication to recreate all database structure and the first population of the tables.
For this they use AddSubscription .. Syncronize and the DropSubscription
They use the another 4 publications to sync particular tables because they don€™t want to sync everything, every time. All publications point to the same snapshot.
Each time they want to use one of this publication they instance the SqlceReplication object, then AddSuscription.. Synchronize .. then DropSubscription..
They have one of this publications that use a filter 1=0. Doing the previous steps SQLCE doesn€™t track the change and doesn€™t upload the data of the sql ce table to the server. It seems SQL Server recognize it as a new Sincronization, delete the records of the client and doesn€™t upload the changes (if I don€™t do the DropSubscription it works perfect) I can reproduce that using a device or an emulator.
They have 100 devices via GPRS - VPN. They need to be assure that this Add / DropSubscription will assure they don€™t lose the information. They want to assure all the process of sync is fine just to go to the carrier and make some GPRS connection monitor and test.
How is the best way to approach where the NET CF application needs to use more than one publication to the same database? I have suggested to put all the transactional tables in the same publication but due the business case it is not possible. What are the risks to use many publications?
Another question€¦ each X hours they do a full sync using the first subscription the application returns the next message: The snapshot for this publication has become obsolete. Why this happens? Due the changes in the another publications? How could we manage that to avoid this message? Note: All the test were doing via cradle and GPRS with the same results.
I have a windows mobile 5.0 pocket PC application that performs replication between a Publihser (PC, SQL SERVER 2005), and subscriber (SQL MOBILE) on the pocket PC. The problem I am having is as follows
I created a bidirectional publication (SQL SERVER 2005). Then the pocket pc application subscribe to it (SQL Mobile). Pocket PC app add some records and then synchronise the data. Lets suppose the Pocket PC app adds 2 records on SQL Mobile in a table with primary key 2000 and 2001, which also reflected on the server after syncronisation.
Now for some reason I had to delete the publication and recreate it. My pocket PC resubscribed to the new publication, synchronise the data and get records 2000 and 2001 in SQL Mobile db. Now when the pocket Pc app tries to add a new record to it, it comes up with the error something like "duplicate values not allowed". What it is trying to do is, it is trying to add a new record with id 2000, which is already there in the table and therefore ending up throwing exception.
Can anyone please tell me what is the solution to this problem. Am i missing anything? Do i need to do something with configuring publication while recreating it after deleting it.
I've been trying to convert an application to use the CF 2.0, and of course to SQL Server Mobile. There have been some kinks along the road, but I've worked all of them out except an error on replication. When I call the SqlCeReplication's Synchronize() method, the connection goes fine, it works for about 20-30 seconds, and then comes up with the following error:
Error code: 0x80004005 Message: The data types cannot be converted implicitly. [ Source data type = nvarchar,Destination data type = image ] Native error: 25932 Source: Microsoft SQL Server 2005 Mobile Edition Error Param: nvarchar Error Param: image
I've tried upgrading from SQL Server 2000 to 2005 to see if that helped, but got the same result. I even tried running this from a fresh install of SQL Server 2005, hoping that'd integrate better with SQL Server Mobile, but that didn't help either.
I found a knowledge base article about error code 0x80004005: http://support.microsoft.com/kb/912428 However, none of my tables are even remotely close to having 127 columns, so that can't be it.
I do have an image data type column in one of my tables, but why is a column being converted from nvarchar to image? Both SQL Server 2005 and SQL Server Mobile support the image data type, so I don't understand how that could be causing a problem in the first case.
Any ideas? I've run out of things to try and would appreciate any feedback.
We are trying to setup ssl for a merge replication mobile application. We use our own internal certificate authority to generate ssl certs, but cannot seem to get the one for our mobile merge replication to work. I see some other post about using third party vendors but is this a must? We are using .NETCF 2.0 WM 5.0. Thanks in advance.
I have been experiencing some difficulties with poorly performing synchronizations using replication from SQL Server 2005 to SQL Server Mobile running on Windows Mobile 5 devices. Currently there are two main databases (each client will only use one of them), the 1st one has around 500,000 rows, and the 2nd has about 1,200,000 rows. The initial synchronization for the 1st database takes around 45 minutes, and for the 2nd, around 2.5 hours. This is quite long, but we have comforted our clients by saying that this is a one time delay, and that further synchronizations will be much quicker. Well, synchronizing the data after this is usually quite speedy, however, things get bad rather quickly when the number of changes increases.
In normal cases, the client will have at most a few thousand changes and all is well, the synchronization will typically be under a few minutes - no big deal. Once in a while though, there are a substantial number of changes to the database (from the SQL Server 2005 side), perhaps around 50,000 changes. When this happens, the synchronization process doesn't seem to ever finish (I've left it over the weekend and come back to find it still synchronizing). For the record, there seems to be a level at which the database will finish synchronizing, but be agonizingly slow - around 10,000 to 20,000 records will finish eventually (but take a few hours, at which point it's faster to just blow away the database and start again from scratch). This is obviously not acceptable, and I need to find a way to resolve this. Does anyone have any thoughts?
While on this topic, why does this synchronization process take so long anyways? The snapshot creation (even for the database with millions of rows) finishes in a couple minutes, and the actual transfer of data shouldn't take more than a few minutes. The device can't possibly be storing the database content in memory (the SDF file ends up being between 40MB and 100MB), but when I watch network activity, there tends to be an initial busy period, then a periodic and fairly small spike every few seconds until the process completes, so the connection isn't being saturated at all.
At this point, I am almost considering breaking the nice database design I have and creating combined logical records to see if reducing the number of rows may help. I'd really prefer not to have to go this route though, so if anyone has any suggestions, I'd really appreciate some feedback.
We are using SQL 2005 (SP1) and mobile agents with SQL Mobile. We are seeing an excessive number of updates after a device's database is reinitialized. My understanding was that if I generate a new snapshot or reinitialize all subscriptions (from the server), the devices would only get what the database looks like right now (inserts only) after syncing and/or reinitializing, but they are actually getting the right number of inserts and a huge number of updates in Replication Monitor. Any ideas?
I understand that it is possible to set filters dynamically using functions 1) SUSER_SNAME() 2) and HOST_NAME(). SUSER_SNAME() returns the login credentials used in the subscritption. HOST_NAME() returns the host machine and can be overloaded with buisiness information.
My application should work as below; 1) User enters the login credentials. 2) Some information as the User name passed to server and if the user name is valid , the rows related to this particular user get downloaded to device.
A new user is added directly in the Users table in master database.
My questions are : 1) If I have 3000 users , should I create 3000 subscriptions with 3000 HOSTName or Login credential information to differentiate btween users? 2) If yes , other than using the wizard is there any scripts available to create large number of subscription? 3) If add subscription programatically , should I re-initialise subscription for each new user which is assigned with a diferrent host name value?
I have developed a mobile program with sql server 2000 merge replication. It works fine in Win mobile 2003 OS, but, not working at all after I upgrade the mobile OS to Win mobile version 5.0
I developed a mobile application (CF 2.0) that uses merge replication to synchronize data between SQL Server Mobile and SQL Server 2000 SP4. The application uses asynchronous synchronization (BeginSynchronize method) to initiate the replication and update the user about the progress. The application worked perfectly on PPC2003 and Windows CE .Net 4.2 platformes.
The problem started when I moved it to WM5 platform. We're using Symbol MC70 devices.
When I start the replication for the first time it synchronizes without a problem. If I perform additional synchronizations(updates) it synchronizes without a problem. If I exit the application and start it again the sync process hangs when I try to synchronize it(to deliver updates).
I have a windows mobile 5.0 application that syncronises with SQL Sever 2005 (Merge Replication). The replication works fine without SSL. But when using SSL it doesn't work .On the device i get an error
28037, A request to send data to the computer running IIS has failed.
I have created a a Wild Card Certificate (*.domain-name.net) using Microsoft Certificate Services (Stand Alone) and setup the replication website with replication virtual directory under it , in IIS, to use this certificate. The host header for the replication site is set to "sql.domain-name.net". I have binded the host headers to the port as well.
I can access the https://sql.domain-name.net/replication/sqlcesa30.dll from remote computer and device and it says Microsoft SQL Server Compact Edition Server Agent, that means it is setup correctly.
I have installed the certificate authority and its wild card certificate on the device Root Certificates. Now when I call repl.syncrhonise() from device .. it throws exception with error 28037, A request to send data to the computer running IIS has failed.
which i think means, it can't find the service url.
I am not sure what is the problem..something to do with Trust - SSL certificates... Is there any thing i am missing ?
Hi , I would like to get your advice in an issue that I am facing regarding merge replication. The flow is like: 1) User enter his login name and password. 2) Host_name is set as the login name that the user enters. 3) Based on the HOST_NAME property after filtering user gets the records relevent only to him (Differnet subscriber may use same mobile device).
4) He make some changes in the local sdf according to the business logic. 5) The application Syncs with server on the next login session.
My issue is when I am trying to run the application in emulator exactly at the sdf updating part the application terminates. Error mess: Connection to Remote Device has been lost..... If I execute the same sql insert query it works om the local sdf and master database. Emulator used where Pocket PC 2003 SE and Windows Mobile 6 classic emulator. I have installed 1) Visual Studio 2005 SP 1 2) net compact framework SP2.
When I comment all the code related to Sync ,application works witout any issue. And the same application works in my "I mate kjam".
The code that I use is given below: ==========================================================================
public void Sync(string hostname, int newsub) // Parameters for HOSTNAME and flag to denote new user or existing //user.
I'm currently investigating the feasibility of having SQL Mobile on a number of devices running Windows CE. These devices will have to synchronize with the server (either using merge replication or RDA) over GPRS. The problem I have is that some of these devices will never be online. Is there are a way of synching these offline devices? The model I had in mind was using a USB key (or some other storage device) to download the latest updates from an online device and transferring this data to the offline device, and vice versa e.g. from offline to online and then merging. Is this feasible?
This is just too simple. I must be doing something wrong. I have tried everything, redoing the SQLMobile merge publication, setting permissions, and need help ASAP.
The basic test with the http://localhost/sqlmobile/sqlcesa30.dll returns the message:
SQL Server Mobile Server Agent 3.0
I have tried the merge replication with both my local SQL Server 2005 installation and a remote development box. Both instances return the same error.
I am able create and replicate a database using the sample application:
I am in the process of testing a SQL 2005 Std x64 server with merge replication using Windows Mobile 5.0 clients and SQL 2005 Mobile. The test DB is a copy of the currently active DB, but has been expanded to include some new tables to support planned application functionality extensions.
Once the publication exceeds 97 Articles, the error is thrown that "The buffer pool is too small or there are too many open cursors". If I drop one article everything is fine. I ran a test with dummy DB that had 100 blank tables, and this initialized just fine on the client. The additional articles I am publishing (the 98th table) is also empty, but it throws the error anyway.
Is there a limit on the total size/number of changes that can be sent? Since I have run tests sending over 64,000 changes to a client during initialization this does not seem to be the case (I am only attempting a little more than 9,700 changes on this initialization).
Some other ideas that have been tested without success are to stop the user triggers from propagating, and toggling the AWE setting for SQL. The Replication Monitor does say the client completes replication, and it seems to choke at the very end of completing replication when it attempts to write to the tracking tables. The last successful action is sys.sp_MSadd_merge_history90, and it appears to be acting on the last table added to the publication.
There does not appear to be a limit on the number or articles, since I can publish more articles in a dummy DB than I am able here, so it seems to be something to do with size. Any information would be helpful, this is a very frustrating issue. Thanks!
I have a question for anyone who mas some tips/pointers for optimizing SQL merge replication publications.
The front end web server is running IIS 6.0 on Windows 2003 x86 Server Standard (Server A). The back end database server is running SQL 2000 Standard on Windows 2003 x86 Standard (Server B). The merge replication clients connect via HTTPS over the Internet from a custom C#.NET 2005 application using SQL 2005 Mobile running on Windows Mobile 5.0 (Client).
The publication itself has several filters on it. The entry point uses the user's Windows username to start the filter. Based on the user, it then filters the records in multiple tables. There are 68 articles and 44 filter statements. The filters extend multiple layers deep, in other words they are not all filtering off the HOST_NAME() variable, some tables filter from records in tables that filter from the HOST_NAME() variable. The publication is set to minimize data sent to the clients, and considers a subscription out of date if it has not synced in the last 4 days. All the rowguids are indexed as well.
There are approximately 35 clients actively using the application at any given time. On average, a client will initiate a merge replication 3-4 times per hour from 8am-5pm. Generally, a sync will take between 10 seconds and 2 minutes to complete, with most of them being around 30 seconds on average.
When a client starts a sync, there is a spike to about 50% on the server's CPU graph. If multiple clients attempt to sync at the same time the CPU utilization can be pushed to 100% for extended periods (more than 30 seconds).
I recently completed a project to increase the bandwidth available to the clients, and plan to reduce the number of filters significantly (although this will obviously increase the amount of data going to the clients and the storage needs on the individual devices). I also plan on changing the setting to not minimize the amount of data sent to the clients.
Having said all that, does anyone have any information about how to further optimize merge publications to mobile clients? The next publication will be on SQL 2005 x64 Standard if I can solve the issues in the text environment. I would like to enhance the publication as much as possible to make the end user experience better than it currently is.
We have setup a 32-bit IIS server on a 32-bit machine. Installed necessary SQL Server components (32-bit replication components). We have installed SQL Server 2005 64-bit SP1 with latest hotfixes on a 64-bit machine.
On the Mobile device we installed SQL Server 2005 Mobile.
When we start mergereplication the problem we have is error 28009 (An instance of the SQL Server Reconciler cannot be created) on the mobile device. I read allot about it, but still have a questetion.
Should this work?
I found the doc: SQL Server 2005 Upgrade Technical Resource Guide: Note: If your upgrade involves SQL Server CE subscribers, you must perform additional actions on the IIS server. You will need to install SQL Server 2005 client connectivity components along with SQL Server Mobile Edition components on the IIS server. You will also have to replace sqlcesa30.dlll, sqlcerp30.dll, and all the replication components on the IIS server.
From this I conclude it should work or is the doc in error?
If it does not, what can we do?
32-bit SQL Server 2005 on the 64-bit machine should work. (Can a 64-bit SQL Server 2005 run alongside 32-bit SQL Server 2005?).
I am developing a application where the database needs to be deployed from the central database server which is sql server 2005, and we have only few fields and few new tables which need to be deployed into pocket pc using sql mobile from sql server 2005. We would like to design the database in sql server 2005 for mobile, which will be only structure and will be deployed into PDA using web service.
Hi All, this system is scheduled to go live in near to a day... but i have hit an issue when switching on SSL. Any help would be greatly appreciated.
Device Env: Windows Mobile 5.0 + Messaging and Security Feature Pack SQL Server Mobile 2005.
Merge replication works fine without SSL. After running the Configure Web Sync wizzard to setup SSL merge replication no longer works. Note i checked using pocket IE by browsing to https://mycompany.com/pub/sqlcesa30.dll?diag and all worked fine. There was no prompt saying the cert was bad etc.
The certificate is a: Equifax secure global ebusiness CA-1 cert. Signature algorithm md5RSA public key RSA(1024 bits) thumbprint algorithm sha1
Stacktrace given is: - ex {"A request to send data to the computer running IIS has failed. For more information, see HRESULT."} System.Data.SqlServerCe.SqlCeException - Errors {System.Data.SqlServerCe.SqlCeErrorCollection} System.Data.SqlServerCe.SqlCeErrorCollection Count 1 Integer Item In order to evaluate an indexed property, the property must be qualified and the arguments must be explicitly supplied by the user. System.Data.SqlServerCe.SqlCeError HResult -2147012858 Integer InnerException Nothing System.Exception Message "A request to send data to the computer running IIS has failed. For more information, see HRESULT." String NativeError 28037 Integer Source "Microsoft SQL Server 2005 Mobile Edition" String StackTrace "at System.Data.SqlServerCe.NativeMethods.CheckHRESULT() at System.Data.SqlServerCe.SqlCeReplication.Synchronize() at MyApp.Helper.Replication.SynchronizeInit() at MyApp.CallSynchronize() at System.Windows.Forms.Control.OnGotFocus() at System.Windows.Forms.Control.WnProc() at System.Windows.Forms.ContainerControl.WnProc() at System.Windows.Forms.Form.WnProc() at System.Windows.Forms.Control._InternalWnProc() at Microsoft.AGL.Forms.EVL.EnterMainLoop() at System.Windows.Forms.Application.Run() at MyApp.Program.Main()
Hi We're having problems with push replication to multihomed clients. if the DNS contains multiple IP's and one of those are not reachable from the sql server. the replication fails. no matter order of IP adresses. i wrote a DNS proxy which re-ordered the IP's so that the "working" IP would come first in the list but no success until i filtered out so that the DNS proxy only replied with one, the working, IP.
the replication is part of a commercial application which we have no control over. are there any settings on the server side that can help here? I really want to fix the source of the problem and not patch it with a proxy.
any ideas are welcome. the server is sql 2005 standard and the clients are running 2005 express
I am new to replication but I have a question, I have my server which is using a transaction replication process and a client with using SQL Express with replication turned on. I have the identical DB on both nodes yet when I subsrcibe to the server from the client, data is transfer but for some reason, all of my stored procedures are renamed with sp_MSDel_DBOxxxx. How do I keep SQL from renaming these SP's? The server maintains the origial names to the SPs its just happening on my client.
I have smilar kind of an issue with replication. I had sucessfully done replication with Sqlce2.0 on sql server 2000. In development machine I had VS 2003, sqlce development tools.
Now I use the same code done in VS 2003 into VS2005, it sucessfully converted the code.
In server machine (win 2003) I installed sql server 2000, sql server 2000 service pack 4, SP4 merge replication components, sql server 2005 mobile server tools and .Net framework 2.0. Created pubication sucessfuly. In this machine I configured IIS as per the web synchronization wizard. Gave anyonymous permissions. Virual direcory is created sucessfully. I tested the server agent in IE http://myservername/aliasname/sqlcesa30.dll.
SQL Server Mobile Server Agent 3.0 is shown
My application opened successfuly in windows mobile 5.0 Pocket PC emulator. When try to sync its dislays error "A request to send data to the computer running IIS is failed, see Hrresult"
No firewall in both development and server machines.
The same code works if its sqlce20 perfectly with vs2003 code. Not in this