#Getting Started ## Quick Start At the moment, TDengine only runs on Linux. You can set up and install it either from the source code or the packages. It takes only a few seconds from download to run it successfully. ### Install from Source Please visit our [github page](https://github.com/taosdata/TDengine) for instructions on installation from the source code. ### Install from Package Three different packages are provided, please pick up the one you like.
For the time being, TDengine only supports installation on Linux systems using [`systemd`](https://en.wikipedia.org/wiki/Systemd) as the service manager. To check if your system has *systemd*, use the _which_ command. ```cmd which systemd ``` If the `systemd` command is not found, please [install from source code](#Install-from-Source). ### Running TDengine After installation, start the TDengine service by the `systemctl` command. ```cmd systemctl start taosd ``` Then check if the server is working now. ```cmd systemctl status taosd ``` If the service is running successfully, you can play around through TDengine shell `taos`, the command line interface tool located in directory /usr/local/bin/taos **Note: The _systemctl_ command needs the root privilege. Use _sudo_ if you are not the _root_ user.** ##TDengine Shell To launch TDengine shell, the command line interface, in a Linux terminal, type: ```cmd taos ``` The welcome message is printed if the shell connects to TDengine server successfully, otherwise, an error message will be printed (refer to our [FAQ](../faq) page for troubleshooting the connection error). The TDengine shell prompt is: ```cmd taos> ``` In the TDengine shell, you can create databases, create tables and insert/query data with SQL. Each query command ends with a semicolon. It works like MySQL, for example: ```mysql create database db; use db; create table t (ts timestamp, cdata int); insert into t values ('2019-07-15 10:00:00', 10); insert into t values ('2019-07-15 10:01:05', 20); select * from t; ts | speed | =================================== 19-07-15 10:00:00.000| 10| 19-07-15 10:01:05.000| 20| Query OK, 2 row(s) in set (0.001700s) ``` Besides the SQL commands, the system administrator can check system status, add or delete accounts, and manage the servers. ###Shell Command Line Parameters You can run `taos` command with command line options to fit your needs. Some frequently used options are listed below: - -c, --config-dir: set the configuration directory. It is _/etc/taos_ by default - -h, --host: set the IP address of the server it will connect to, Default is localhost - -s, --commands: set the command to run without entering the shell - -u, -- user: user name to connect to server. Default is root - -p, --password: password. Default is 'taosdata' - -?, --help: get a full list of supported options Examples: ```cmd taos -h 192.168.0.1 -s "use db; show tables;" ``` ###Run Batch Commands Inside TDengine shell, you can run batch commands in a file with *source* command. ``` taos> source