Professional Documents
Culture Documents
SQL Admin Question-Interview
SQL Admin Question-Interview
SQL Admin Question-Interview
Note: While hiding a named instance, we need to provide the port number
in the connection string so that even if the browser is running it is possible
to connect to the hidden instance.
Yes. we can add CPUs physically by adding new hardware, either logically by
online hardware partitioning or virtually through a virtualization layer.
Starting with its 2008 version, SQL Server supports CPU Hot Add. There are
a few requirements to use CPU Hot Add:
Once the CPU is added, we need to run RECONFIGURE, and then SQL Server
recognizes the newly added CPU.
Learn about SQL Server Certification and leave behind your peers!
TELNET PORTNUMBER
TELNET PAXT3DEVSQL24 1433
TELNET PAXT3DEVSQL24 1434
Common Ports:
DAC (-A):
Emergency:
Preferring NT authentication
Using server, database, and application roles to control access to data
Securing physical database files using NTFS permissions
Using an unusable SA password for restricting physical access to SQL
Server
Renaming the Administrator account on the SQL Server computer
Disabling the Guest account
Enabling auditing using multiprotocol encryption
Setting up SSL and firewalls
Isolating SQL Server from the webserver
Do you have any more queries on this? Visit our SQL Server
Community and clarify all your doubts today!
9. Which are the third-party tools used in SQL Server and why would
you use them?
SQL Check (Idera): For monitoring server activities and memory levels
SQL Doc 2 (Redgate): For documenting databases
SQL Backup 5 (Redgate): For automating the backup process
SQL Prompt (Redgate): For providing IntelliSense for SQL Server
2005/2000
LiteSpeed 5.0 (Quest): For backup and restore processes
Hotfixes are software patches applied to live systems (the ones still
running). A hotfix is a single, cumulative package that includes one or more
files used to address a problem in a software product (i.e., a software bug).
In the Microsoft SQL SERVER context, hotfixes are small patches designed to
address specific issues, most commonly to freshly-discovered security holes.
For example, if a select query returns duplicate rows with aggregations, the
result may be wrong. This can be fixed by a hotfix.
Recommendations:
12. Which key provides the strongest encryption in SQL Server DBA?
AES (256-bit).
13. Which port do you need to open on your server firewall to enable
named pipe connections?
To enable named pipe connections, we need to open Port 445. Named pipes
communicate across TCP Port 445.
Cluster Administrator checks the SQL Server group where we can see the
current owner. The current owner is the active node and the other nodes are
passive nodes.
16. What are the common trace flags used with SQL Server?
No. The only way if we want to get a backup is by using Windows backup for
option resource MDF and IDF files.
Upgrade Advisor can analyze remote instances of SQL Server, except for
SQL Server Reporting Services. To analyze Reporting Services, Upgrade
Advisor must be installed and executed on the Report Server.
To upgrade SQL Server 2000 to SQL Server 2008, the safest approach would
be a side-by-side upgrade. We can do this either by using backup and
restore or by detaching/attaching the database files. However, it is
suggested to use the former as it is a safer approach. The steps are as
follows:
Run the Upgrade Analysis tool from Microsoft. Address any issues raised
there, first
Identify DTS packages. These must be migrated manually unless we buy
Pragmatic Works
Rebuild the DTS packages as SSIS
Script out all SQL Agent jobs
Script out all security
Backup the systems and validate the backups (preferably by restoring
them to another system)
Run the security script on the new system
Run restore on the new system
Validate the databases by running DBCC
Manually update all statistics
Run the SQL Agent script
20. Can you detach SQL Server 2005 database and attach it to a SQL
Server 2008?
Yes. SQL Server 2005 databases are compatible with SQL Server 2008.
Attaching a SQL Server 2005 database to SQL Server 2008 automatically
upgrades the SQL Server 2005 database to the latter, and the database is
then no longer usable by the SQL Server 2005 installation.
21. Can you detach a SQL Server 2008 database and attach it to a
SQL Server 2005?
No. The only way to move a SQL Server 2008 database to a SQL Server
2005 is by transferring the data using methods, such as Data
Transformation Services (Import/Export), SSIS, BCP, etc., or by using a
query between linked servers.
22. When you upgrade a SQL Server, the upgrade wizard seems to
stop responding and fails. Why?
If applications or services have opened ODBC connections to SQL Server
2005 during the conversion process, they may not allow SQL Server to shut
down completely. The conversion process will not proceed to the next step if
it does not receive verification that SQL Server has been completely
stopped.
If the legacy SQL Server instance is replaced by a new SQL Server 2008
instance, rolling back an in-place upgrade can be complex and time-
consuming; whereas, in a side-by-side upgrade, the legacy instance remains
available if a rollback is needed.
The below command causes DBCC CHECKDB to check the database for
column values that are not valid or out of range:
DBCC CHECKDB ('TestDB') WITH NO_INFOMSGS, DATA_PURITY
With this command, DBCC CHECKDB detects columns with date and time
values, which are either larger or less than the acceptable range for the
DATETIME data type. It also limits checking the integrity of the physical
structure of the page and record.
One is the READ_COMMITTED isolation level. This is the only level that
supports both a pessimistic (locking-based) and an optimistic (version-
based) concurrency control model.
The other is the SNAPSHOT isolation level that supports only an
optimistic concurrency control model.
The database engine uses intent locks to protect placing a shared (S) lock or
an exclusive (X) lock on a resource (lower in the lock hierarchy). Intent locks
are named thus because they are acquired before a lock at the lower level
and therefore signal the intent to place the locks at a lower level. Intent
locks serve two purposes:
From the execution plan, we can find out the bottlenecks and give possible
solutions to avoid latency
32. What are the permissions required to view the execution plan?