SQL SERVER Firewall solution

Dear all
Please tell how to have a connection of SQL Server DB present in the server protected by a windows firewall with a simple JAVA application running on the client machine present within the same LAN.Its just a simple window based application being developed in java
The problem :-
Evertime i try to connect with the server database i get ther error Connection timeout error and if i put the firewall off on the server i get a good connection with the database.
Please provide solution for this prolem..please keep this in mind that firewall cannot be put off :)

Please tell how to have a connection of SQL Server
DB present in the server protected by a windows
firewall with a simple JAVA application running on
the client machine present within the same LAN.Its
just a simple window based application being
developed in javaWrite a servlet that runs inside the firewall, on the same side as the database. Port 80 is open in the firewall. Have the servlet intercede with the database on the client's behalf and send back results.
The problem :-
Evertime i try to connect with the server database i
get ther error Connection timeout error and if i put
the firewall off on the server i get a good
connection with the database.This is good. You should not want your database to be exposed to clients outside the firewall.
Please provide solution for this prolem..please keep
this in mind that firewall cannot be put off :)See above. Your client should not connect directly to the database.
%

Similar Messages

  • SQL Server Firewall Port Monitor

    I've got this annoying critical alert since weeks.
    The health explorer somehow seems not to see that the ports 1433 and 4022 are open for my SCOM Server.
    Even if i turn off the firewall the monitor will jump to the red little cross.
    I have read that i should just ignore the critical alert and wait for a bug fix, but after a few weeks i just want a single green line of my servers.
    Does anybody know how i can fix this bug or did you guys just overwrite the event?
    Cheers
    Quote:
    The SQL Server port (default 1433) for communications with
    the Configuration Manager site system roles and the provider, or the SQL Server
    Service Broker port (default 4022) used for Configuration Manager replication
    communications between parent and child SQL Servers, is blocked by a firewall rule on the network or server and is preventing communication using the configured ports.
    A network issue may have prevented the communication over
    one or both of these ports.

    You can override this monitor or disable it. but also check hman.log file has no error.
    You can also refer below link
    http://social.technet.microsoft.com/Forums/systemcenter/en-US/e5260e71-1c76-431e-b4a2-fa0b86ba5d8c/configmgr-2012-mp-sql-port-on-firewall-not-open-even-though-it-is?forum=operationsmanagermgmtpacks
    Please remember, if you see a post that helped you please click "Vote As Helpful" and if it answered your question, please click "Mark As Answer"

  • Basic tips to recover MDF file from corrupted SQL server

    Hi users,
    share the basic tips of MDF file recovery with good example and when the tool support with all over MS windows and MS SQL server.

    Basic solution to recover MDF file from corruption is to run DBCC statements. It is a set of SQL statements -
    1. Dbcc checkdb ('database_name') with no_infomsgs
    You do not need to repair file if the above statement is executed without any errors. Before executing the repair operation, you need to set the database in single user mode by executing:
    2. Alter database 'database_name' set SINGLE_USER
    You can now start repairing process by using Repair_Rebuild model by executing:
    3. Dbcc checkdb('database_name', REPAIR_REBUILD)
    If this statement executes successfully, then execute 5.5 else execute:
    4. Dbcc checkdb('database_name', REPAIR_ALLOW_DATA_LOSS)
    This statement may lead to data loss. If it is executed properly then execute 5.5 else execute:
    5. 5.1 Alter database 'database_name' set EMERGENCY
    5.2 Alter database 'database_name' set SINGLE_USER
    5.3 Dbcc checkdb ('database_name', REPAIR_ALLOW_DATA_LOSS) with no_infomsgs, all_errormsgs
    5.4 Alter database 'database_name' set ONLINE
    5.5 Alter database 'database_name' set MULTI_USER
    Click here to get complete guide to repair MDF file.

  • Ncache, MemCache, and SQL Server tables With Joins

    Hello,
    I'd like to look into a caching solution which could not only store results of a query, but also the table structures to do joins on the caching layer eliminating the need to do it on the SQL Server side.  Essentially I want to cache the customers table
    and orders table so the look ups are done on the caching software, does anyone know of a good solution for this?
    Support my SQL MCM & Internal Training blog on AliRazeghi.Com.  Have a tough I.T. job and you need to talk to someone with no obligation?  Contact my certified
    associates and I at Rosonco.com!
    If you find a question answered please click 'mark as answer' or 'vote as helpful'.  This will help other users find answers quickly.  Thanks for visiting!

    Just to get an update on microsoft SQL Server caching solutions - what are they and where can we learn more about them?  

  • I cannot debug with SQL server 2008 SSMS asks for Firewall permission?

    hi friends,
    I run SQL server 2008 R2 developer edition on windows 8 basic edition. SQL server is installed in my local machine. when I tried to debug a sql script it asked the firewall permission as show on image
    when googled I found this
    Article from MSDN with fix tool but it cannot installed on my Windows 8 OS, is there way to fix it without giving any unauthorized access to my system?
    thanks
    I use Visual studio 2012 Ultimate and SQL server 2008 developer edition!

    Hi,
    The hotfix you provide applies for Windows Server 2008.
    The windows firewall on this machine is currently blocking remote debugging.
    According the message, the following ports need to be enabled for remote debugging. Use the procedure that is described in the section
    Configuring a Port in Windows Firewall to enable the following ports through Windows Firewall:
    Ports
    Protocol
    135
    TCP
    Required
    500, 4500
    UDP
    Required if your domain policy requires   network communication to be performed through IPSec.
    See the below article for more information:
    How to: Enable Transact-SQL Debugging
    http://msdn.microsoft.com/en-us/library/vstudio/s0fk6z6e(v=vs.100).aspx
    Thanks.
    Tracy Cai
    TechNet Community Support

  • SQL Server 2012 - Wat Is The Best Solution For Creating a Read Only Replicated/AlwaysOn Database

    Hi there I was wondering if someone may have a best recommendation for the following requirement I have with regards setting up a third database server for reporting?
    Current Setup
    SQL Server 2012 Enterprise setup at two sites (Site A & Site B).
    Configured to use AlwaysOn Availability groups for HA and DR.
    Installed on Windows 2012 Servers.
    This is all working and failover works fine and no issues. So…
    Requirement
    A third server needs to be added for the purpose of reporting, to be located on another site (Site C) possibly in another domain. This server needs to have a replicated read only copy of the live database from site A or Site B, whichever is in use. The Site
    C reporting database should be as up-to-date to the Site A or Site B database as possible – preferably within a few seconds anyway….
    Solution - What I believe are available to me
    I believe I can use AlwaysOn and create a ReadOnly replica for the Site C. If so do I assume Site C needs to have the Enterprise version of SQL server i.e. to match Site A & Site B?
    Using log shipping which if I am correct means the Site C does not need to be an Enterprise version.
    Any help on the best solution for this would be greatly appreciated.
    Thanks, Steve

    for always on - all nodes should be part of one windows cluster..if there site C is on different domain - I do not think it works.
    Logshipping works --as long as the sql on site C is is same or higher version(sql 2012 or above).  you can only do read only.
    IMHo, if you can make site C in the same domain then, Always is better solution else log shipping
    also, if your database has enterprise level features such as - partitonin, data compression -- you cannot restore the database on lower editions- so you need to have enterprise edition.
    Hope it Helps!!

  • SQL Server 2008 R2: which version of Visual Studio do I need to keep database projects and SSIS projects in the same solution

    I need to build a solution containing a database project and an integration services project for SQL Server 2008R2.  Apparently, the subset of Visual Studio tools that comes with SQL Server 2008R2 does not include database projects and does not have
    Team Foundation Server support.  Because of those limitations, I am trying to determine which version of Visual Studio will allow me to:
    1. Build a single solution that includes both a database project and an Integration Services project
    2. For the database project, be able to import a database schema from an existing SQL Server 2008 R2 database, do schema compares and update the project from the database and vice versa
    3. For the Integration Services project, be able to deploy the packages to SQL Server Integration Services on SQL Server 2008 R2 (that is, to the msdb database).
    4. Use Team Foundation Server for source control of the whole solution, including both project types.

    Hi G Britton,
    To build a solution containing a database project and an integration services project for SQL Server 2008 R2 and use Team Foundation Server for source control.
     You can choose to install Visual Studio 2008.
    And as you want to utilize Schema compare and/or Data compare functionalities in Visual Studio, you will need to install the
    Visual Studio Team System 2008 Database Edition or Visual Studio Team System 2008 Team Suite.
    In addition, for Visual Studio issues, I would like to recommend you post the question in the
    Visual
    Studio forums to get better support.
    Reference:
    Team Foundation Version Control
    Compare and Synchronize Database Schemas
    Interoperability and Coexistence (Integration Services)
    Thanks,
    Lydia Zhang
    Lydia Zhang
    TechNet Community Support

  • How to configure Sql Server 2008 R2 for debugging without disabling Windows Firewall?

    When I try to debug a procedure in Sql Server 2008 R2 I get a dialog box telling me to unblock some ports.
    >>
    The Windows Firewall on this machine is currently blocking remote debugging.  Remote debugging requiers that the debugger be allowed to receive informatino from the network.  Remote debugging also requires DCOM (TCP Port 135) and IPSEC (UDP 4500
    / UDP 500) be unblocked.
    <<
    I went to the Windows Firewall and added some new Inbound rules for each of the specified ports (in the images below.  But after this and rebooting entire computer -- I still get this dialog box when I want to go into debug mode from SSMS.  I can
    actually kind of debug standalone code in the SSMS window if I cancel the dialog box.  But I can't debug an actual stored procedure -- which is what I need to do.  I also noticed that my server has an IP address instead of LocalHost.  This is
    not a public Server -- it's my private development machine which is on a peer to peer network (with one other workstation), but I don't need that workstation to be able to access this server..  Would localholst make a difference for debugging?  How
    should I configure the sql server?  The firewall?
    Rich P

    Use PRINT and SELECT for debugging. That's what I do. I used to play with the debugger in SQL 2000 and older days, but I realised that I spent more time on getting it to work that I gained from using it.
    I thought about that.  I guess that IS the way to go.  Very well.  Thank you for the suggestion.   Although, when the debugger does work in the regular window (not a stored proc because it doesn't work there) the debugger IS nice. 
    For debugging my proc I am thinking I will insert param vals into a test collection table for now.  One obscure error I am getting with a particular proc -- in a When loop on one parameter I get the "value will be truncated" error -- but everything
    is set to accept 1000 characters and none of the source data even comes close to 1000 characters.  I have isolated at what point the error occurs and which section of data where the error is occurring but I have not isolated the cause of the error. 
    I cannot reproduce the error when I run the procedure by hand in a regular query window with the exact same code.  The error only occurs when the code is run in the stored proc.
    Rich P

  • Help needed - Planning Server 2012 solution, DC/Exchange/SQL/RDP host/Remote apps etc

    Hi All,
    I have a client needing me to provide a Windows server based solution for their business. I have limited experience with Server 2012, although I have worked with 2008R2 and SBS2011, I am needing some guidance with this 2012 project.
    The client has about 8-10 local users who work at one office with an NBN connection, and 2 other locations that have 3-5 users at each location. I am needing to provide them with a server based solution to manage their data, remote access and also their
    email. They are also likely to expand to another physical office soon.
    I need to provide them with a DC controller, Exchange server and possibly an SQL server in the future. They currently use an Act database, but I have been told that once the database in ACT grows to 4G, a dedicated database is required?
    I am currently thinking of having one physical server and virtualising the additional servers on this platform, however I come from a UNIX background and have not virtualised using Hyper V or ESXi before. I have read a little regarding the CLI and GUI Hyper
    V options, but I really need advice on what will suit my needs best from someone that has done it.
    I am thinking I maybe should recommend one physical machine with Server 2012 Std which, from what I understand, will allow me to install the host hyper V host on the physical machine and then I could possibly install an instance of Server 2012 as
    the DC, Exchange and SQL server on one VM licence, however I have read it is not preferred to have the exchange server on the same VM as the DC but have read that limiting the memory usage of Exchange can negate these issues?
    I will also need to have a terminal server/RDP session host in there as well which I could maybe use the 2nd VM licence for.
    I suppose my question is, considering that I need to end up with a DC, Exchange server, terminal server/RDP session host and possibly a SQL server in the future, am I better off virtualising and running these on a Server 2012 Std licence, that allows a hyper
    v host + 2xVM's or should I be splitting these roles up on different physical machines, keeping in mind costs need to be kept to a minimum.
    Also I need to consider the Microsoft Office side of things. Is it more financially viable to use office licences and use remote apps from the terminal server, or just purchase Office H&B for the workstations/laptops and have their outlook connected
    directly to the exchange server?
    I am concerned from the performance viewpoint that if I run the DC/Exchange and SQL from one VM, then the TS/RDP Host from the other VM licence it may be too much for the DC/Exchange/SQL VM to handle.
    I have used SBS 2011 in a few locations with Exchange and the SQL and DC roles installed on HP DL and ML gen 8 servers, and although they run a little slow on the console, they seem to serve the network clients fine.
    If do end up running on one physical machine the Hyper V host, one VM as a DC, Exchange and SQL server, and the other VM licence as a RDP session host, what sort of spec'd machine would be recommended to be able to do this, keeping in mind
    I usually lean towards HP servers.
    Anyhow, thx in advance and any comments or suggestions will certainly be appreciated.
    Mkm

    Hello,
    sorry but in your case without the knowledge of all major requirements i would suggest that you or your client contact an expert and not work with the forums to get this amount of information and setup requirements.
    Exchange on DCs is NOT recommended, even not from Microsoft. Also it is highly recommended to run at least 2 DC/DNS/GC per domain for failover and redundancy, of course NOT on the same physical machine.
    RDS servers should also run on dedicated machines and not be used for anything else.
    SQL should also run on a separate server.
    You cannot compare SBS version with regular server versions, the concept behind is different.
    With that small amount of users you should consider using an Office365 solution where you could use a plan that fits your needs and have just computers for your client employees.
    But as stated above therefore you should find an experienced consultant.
    Best regards
    Meinolf Weber
    MVP, MCP, MCTS
    Microsoft MVP - Directory Services
    My Blog: http://blogs.msmvps.com/MWeber
    Disclaimer: This posting is provided AS IS with no warranties or guarantees and confers no rights.
    Twitter:  

  • SQL Server 2012 64 bit - reading data from dbf (DBase 3/4/5 or VFoxPro) - solution and examples

    It took me quite a while to find a solution that will enable me to read dbf files from 64 bit SQL server, so i decided to create this guide for all of you guys searching for an answer.
    Download and install Access Database Engine 64 bit : http://www.microsoft.com/en-us/download/details.aspx?id=13255
    Creating Linked server for me is the most elegant solution 
    To create a Linked Server modify following sql statement with your data and execute it:
    EXEC master.dbo.sp_addlinkedserver 
    @server = N'DBFServer', 
    @srvproduct=N'', 
    @provider=N'Microsoft.ACE.OLEDB.12.0', 
    @datasrc=N'D:\DBF\', 
    @provstr=N'dBASE IV'
    You can read data directly without linked server, but i find this less elegant
    To read data directly modify following sql statement with your data and execute it:
    Use KTCDB
    GO
    sp_configure 'show advanced options', 1
    reconfigure 
    GO
    sp_configure 'Ad Hoc Distributed Queries', 1 
    reconfigure
    GO
    EXEC master.dbo.sp_MSset_oledb_prop N'Microsoft.ACE.OLEDB.12.0' , N'AllowInProcess' , 1;
    EXEC master.dbo.sp_MSset_oledb_prop N'Microsoft.ACE.OLEDB.12.0' , N'DynamicParameters' , 1;
    SELECT * FROM OPENROWSET('Microsoft.ACE.OLEDB.12.0',
                           'dBASE IV;Database=D:\DBF\;', 
                           'SELECT * FROM ODMRAD')
    EXEC master.dbo.sp_MSset_oledb_prop N'Microsoft.ACE.OLEDB.12.0' , N'AllowInProcess' , 0;
    EXEC master.dbo.sp_MSset_oledb_prop N'Microsoft.ACE.OLEDB.12.0' , N'DynamicParameters' , 0;
    GO
    sp_configure 'Ad Hoc Distributed Queries', 0
    reconfigure
    GO
    sp_configure 'show advanced options', 0
    reconfigure 
    GO
    I hope this will help you guys avoid frustration and wasting lots of time.

    Visakh, i believe you are mixing terms 'reading' and 'importing', as with solution i proposed you can consume 'live' data without the need to
    import it on every change.
    To clarify : Data in DBF's can change at any point in time, and with my solution whenever you try to read data from either linked server or directly, you will always have most recent data, contrary to the import methods where you are cloning data and actually
    could run into many problems synchronizing original and cloned data.
    Ok..I understand that
    Based on your data volatility you can configure an automated job for executing SSIS package to extract latest of data from dbase. But again it wont be "in real time". There will be slight delay depending on frequency you choose for job.
    I was suggesting it more from a datawarehousing perspective whether data refresh happens only after predefined period (daily,6hrs etc)
    If requirement is to get realtime data when you desire then definitely linked server would be the way to go.
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • SQL Server Analysis Services (SSAS) 2012 High Availability Solution in Azure VM

    I have been testing an AlwaysOn high availability failover solution in SQL Server Enterprise on an Azure VM, and this works pretty well as a failover for SQL Server Databases, but I also need a high availability solution for SQL Server
    Analysis Server, and so far I haven't found a way to do this.  I can load balance it between two machines, but this isn't working as a failover and because of the restriction of not being able to use shared storage in a Failover Cluster in Azure
    VM's, I can't set it up as a cluster which is required for AlwaysOn in Analysis Services. 
    Anyone else found a solution to use an AlwaysOn High Availability for SQL Analysis Services in Azure VM?  As my databases are read-only, I would be satisfied with even just a solution that would sync the OLAP databases and switch
    the data connection to the same server as the SQL databases.
    Thanks!
    Bill

    Bill,
    So, what you need is a model like SQL Server failover cluster instances. (before sql server 2012)
    In SQL Server 2012, AlwaysOn replaces SQL Server failover cluster, and it has been seperated to
    AlwaysOn Failover Cluster Instances (SQL Server) and
    AlwaysOn Availability Groups (SQL Server).
    Since your requirement is not in database level, I think the best option is to use AlwaysOn Failover Cluster Instances (SQL Server).
    As part of the SQL Server AlwaysOn offering, AlwaysOn Failover Cluster Instances leverages Windows Server Failover Clustering (WSFC) functionality to provide local high availability through redundancy at the server-instance level—a
    failover cluster instance (FCI). An FCI is a single instance of SQL Server that is installed across Windows Server Failover Clustering (WSFC) nodes and, possibly, across multiple subnets. On the network, an FCI appears to be an instance of SQL
    Server running on a single computer, but the FCI provides failover from one WSFC node to another if the current node becomes unavailable.
    It is similar to SQL Server failover cluster in SQL 2008 R2 and before.
    Please refer to these references:
    Failover Clustering in Analysis Services
    Installing a SQL Server 2008 R2 Failover Cluster
    Iric Wen
    TechNet Community Support

  • Solution Manager 4.0 & SQL Server 2005

    I see in the documentation the step to install SQL Server 2005 with the 850 character set.  If I want to add the solution manager database to an existing instance (which uses the default char set), but give the database itself the 850 character set...will this cause an issue.  I have read some posts where this causes issues for other SAP products...but have not read anything specific to solution manager.  If this does cause issues, are there any workarounds, other than creating a new instance, changing the default char set for the entire instance, or finding a new db server?

    Dear John,
    unfortunately there is no other solution. To ensure, that the database can work correctly it is necessary, that the SQL Server installation as well as all databases within the instance have the same collation. For new installations the SAP installation tools automatically use BIN2 as this will ensure compatibility with unicode. To find out which collation is installed for the server instance you can use the following query:
    select serverproperty('collation')
    To find out the collation of a specific database you need to execute the following query:
    select databasepropertyex('<db-name>', 'collation')
    The fact that the database collation and the server collation must match has nothing to do with the installed SAP Product - the two collations need to be the same in any case. 
    Please read SAP Note #600027 to find the necessary procedure for changing the server / database collation,
    hope this information helps you,
    kind regards,
    beate

  • HADR Solution for SQL Server Analysis Services (SSAS) 2014 on Azure Iaas

    Hi All
    I am required to build a HA/DR solution for SQL Server and SSAS 2014 on Azure. So far I could build AlwaysOn high availability solution for SQL Server on Azure but haven't found any solution for SSAS.
    Failover Clustering is not an option on azure because of the restriction of not been able to use shared storage. We also determined that the cost savings of using SQL + the cost of the 3rd Party replication tool was a wash (ie no real cost savings).
    Any lead on this would be appreciated.
    Thanks,
    Viral Shah
    Thanks - Viral

    Hi Viral,
    A clustered implementation of SSAS can be configured in Microsoft Azure. Such a configuration would need to meet all the requirements stated in the following document including Active Directory and storage.
    How to Cluster SQL Server Analysis Services
    http://download.microsoft.com/download/D/2/0/D20E1C5F-72EA-4505-9F26-FEF9550EFD44/SSAS_Failover_Cluster_V4.docx
    Thanks,
    Lydia Zhang

  • Why to use SQL Server's native backup facilities, not other backup solution?

    I've been asked in my company: why to use SQL Server’s native backup facilities? Instead, they currently rely on other backup software, like Backup Exec, BrightStor, or even Microsoft System Center Data Protection Manager. Those solutions let the
    company manage all of its backups—including SQL Server—in a single place, whereas SQL Server’s native backup abilities only apply to SQL Server.
    So what does SQL Server native backup facility give us more to be forced to use it?

    Satish and Pawan ... thanks but, a backup solution is just there. they don't need to pay anything. even though, having a backup solution that backup everything on the server, like files, software.. etc is needed regardless if you have SQL Server databases
    or not, and if it does database backup it would be even better and more complete as a backup solution. So sorry your answer is not an enough reason that will force me to leave that complete backup solution and use the SQL Server backup tools specifically to
    backup databases.  
    Olaf ... thanks as well. But I was just counting a number of solutions that i think they are related to backup things. yet I believe that Symantec backup exec does backup for SQL Server database, ain't?! what I understood from the link that you gave me,
    that some backup applications (if not all) use SQL Server backup facilities to do database backup, is what I understood correct? if yes then the question will be, is there any situation or reasons that force me to use SQL Server backup tools even if I have
    those backup solution (that some of them in the backgroud they are using SQL Server backup facilities)? does SQL Server backup tool give me more capabilities in backing up databases than what I find in backup solutions?
    The answer is NO, as of now you get all these features in 3rd party native backups...
    So in nutshell Microsoft never forces you to use SQL Servers Native backup -----The only reason why you get native backup featues is since SQL Server is an Enterprise Solution MS provide you all features in-built within the bundle so that you don't have
    to purchase any other license (incase you\your company doesn't have one already)
    Sarabpreet Singh Anand
    SQL Server MVP Blog ,
    Personal website
    This posting is provided , "AS IS" with no warranties, and confers no rights.
    Please remember to click "Mark as Answer" and "Vote as Helpful" on posts that help you. This can be beneficial to other community members reading the thread.

  • Installing SQL server AlwaysOn in hybrid solution

    Hi,
    I am trying to build a HA solution with SQL 2014 and AlwaysOn. My setup is 3 servers on prem and 1 server in Windows Azure with site-to-site VPN in between. My idea is to use the Azure replica as an async copy of some databases that resides on prem.
    There is currently some guidence on the web how to setup this listener configuration using powershell and probe configuration. This works fine and the database on prem replicates to the secondary copy in Azure and the listener can do
    a failover to the Azure replica. All great so far.
    My question is now: How can I have a second Availability Group=Secondary listener configured between the same Machines?
    Or is it a limitation to this setup, that you can only configure ONE listener to a SQL server within a cloud service in Azure? 
    I guess the limitation will be the same if both machines are located in Azure?
    //Håkan

    Yes. Only one availability group listener is supported per cloud service because the listener is configured to use the cloud service IP address.
    Check this link:http://msdn.microsoft.com/en-us/library/azure/dn425027.aspx

Maybe you are looking for