Co to jest wystąpienie programu SQL Server?


14

Podczas instalacji programu SQL Server 2008 Express pojawia się monit o utworzenie instancji i przerywanie, jeśli nie. Następnie widzę te informacje we wpisie w Sql Server Configuration Manager w SQL Server Services. Co to jest wystąpienie programu SQL Server?

Odpowiedzi:


22

Instancja SQL Server jest kompletnym serwerem SQL i można zainstalować wiele instancji na komputerze, ale może mieć tylko 1 instancję domyślną.

Wystąpienie programu SQL Server ma własną kopię plików serwera, baz danych i poświadczeń bezpieczeństwa.

Ten adres URL może ci pomóc


Czy może być uruchomionych więcej niż jedna instancja w tym samym czasie?
pupeno

1
Tak, jednocześnie może działać więcej niż 1 instancja. Potrzebujesz tylko unikalnej nazwy dla każdej instalowanej instancji (jak również ścieżki systemu plików)
Wayne

4
Możesz mieć nawet jedną instancję SQL 2000, a drugą 2005; największym gotcha z wieloma instancjami jest zarządzanie pamięcią, jeśli użyjesz ustawień domyślnych, wszystkie instancje będą próbowały przejąć całą pamięć, najlepiej jawnie ograniczyć maksymalną pamięć dla każdej instancji.
SqlACID

5
SQL 2000 obsługuje 16 instancji. SQL 2005 i SQL 2008 obsługują do 50 instancji na komputer. Możesz uruchomić SQL 2000 i SQL 2005 na tym samym komputerze lub SQL 2005 i SQL 2008 na tym samym komputerze. Jednak nie można uruchomić SQL 2000 i SQL 2008 na tym samym komputerze.
mrdenny

1
Należy pamiętać, że nie wszystkie usługi SQL Server obsługują „instancję” lub wiele instancji. Na przykład usługi integracji są instalowane tylko raz na hosta systemu Windows. Te instancje obejmują instancje Express, które mogą być instalowane przez aplikacje.
Steve Jones

2

INSTALACJA SERWERA SQL Instancja aparatu bazy danych jest kopią pliku wykonywalnego sqlservr.exe, który działa jako usługa systemu operacyjnego. Każde wystąpienie zarządza kilkoma bazami danych systemu i jedną lub większą liczbą baz danych użytkowników. Każdy komputer może uruchamiać wiele wystąpień aparatu bazy danych niezależnie od innych wystąpień.

SQL Server składa się z trzech głównych części: 1. Silnika, który jest oprogramowaniem uruchomionym przez kilka usług Windows, które wyszukuje, sortuje i wykonuje inne działania; 2. Metadane, takie jak system główny i bazy danych msdb; 3. Bazy danych użytkowników, w których przechowywane są dane.

The master database contains the information that the engine reads when it starts up. It includes such things as security settings, file locations, sort orders, and database locations. The msdb database contains the information used by the SQL Server Agent program and information about maintenance plans. Yet another system database, called model, is the "template" from which other databases are created. Finally, the tempdb database is the "scratch" area that the engine software uses. This format holds true for all versions of SQL Server, although other control mechanisms are also implemented as Dynamic Link Libraries, or DLL’s.

This means that a single installation of SQL Server has only one set of certain data, such as server-level security credentials, scheduling information, temporary files and other meta-data.

Beginning with SQL Server 2000, you can run multiple copies of the software, using what Microsoft calls Instances. Instances share a few files between them, mostly dealing with client tools. This allows you to have two different system administrators (sa accounts) and other server-level security on the same hardware. So if you have different security needs, say running more than one company with different administrators, you can install multiple copies of SQL Server on the same hardware.

Another advantage is that since some of the files that run the Instance are duplicated, you can apply service packs separately to each Instance. That way you can host several applications on the same hardware that require different service pack levels.

Instancje umożliwiają także pracę z wieloma wersjami, a nawet edycjami produktu. Instancje można zainstalować w dowolnym momencie, nawet po zainstalowaniu i uruchomieniu programu SQL Server przez pewien czas. Tak więc w przypadku wystąpienia (bez zamierzonej gry słów) można zainstalować program SQL Server 2005 Express Edition, SQL Server 2005 Enterprise Edition, SQL Server 2008 Standard Edition i SQL Server 2008 R2 Developer Edition, wszystkie na tym samym sprzęcie.

If a connection request specifies only the name of the computer only, then connection is made to the default instance. A named instance is one where you specify an instance name when installing the instance. A connection request must specify both the computer name and instance name in order to connect to the instance. The computer name and instance name are specified in the format computer_name\instance_name.

Instancje dotyczą przede wszystkim silnika bazy danych i jego komponentów pomocniczych, a nie narzędzi klienta. Po zainstalowaniu wielu instancji każda instancja otrzymuje unikalny zestaw: 1. Systemowych i baz danych użytkowników. 2. Usługi SQL Server i SQL Server Agent. W przypadku instancji domyślnych nazwy usług pozostają MSSQLServer i SQLServerAgent. W przypadku nazwanych instancji nazwy usług są zmieniane na MSSQL $ instancename i SQLAgent $ instancename, umożliwiając ich uruchamianie i zatrzymywanie niezależnie od innych instancji na serwerze. Silniki bazy danych dla różnych instancji są uruchamiane i zatrzymywane przy użyciu powiązanej usługi SQL Server. Usługi SQL Server Agent zarządzają zaplanowanymi zdarzeniami dla powiązanych wystąpień silnika bazy danych. 3)

Korzystając z naszej strony potwierdzasz, że przeczytałeś(-aś) i rozumiesz nasze zasady używania plików cookie i zasady ochrony prywatności.
Licensed under cc by-sa 3.0 with attribution required.