MySQL/MariaDB Resource Web Pages
CSC instructors can request MySQL accounts for their classes by sending an email to csc_help@ncsu.edu. Include: course, section number. If you want accounts for your TAs please include their name(s)with their unity IDs.
IMPORTANT: Students are responsible for their own database backups. Also, MySQL accounts are permanently deleted at the end of each semester.
How To's
- Logging in to your MySQL class account
- Changing your MySQL password
- Connecting to Database Using Eclipse
Logging in to the MySQL Class Server
statements that you need to enter are in bold or in red
. When the prompt “MariaDB[(none)]>” is returned, your MySQL login was successful! IMPORTANT: access to this MySQL server is restricted to campus IPs only and/or via vpn.ncsu.edu
- You need an ssh client. We recommend Putty. For Mac users use the Terminal app.
- Launch your ssh client and open a secured connection to the remote host: remote.eos.ncsu.edu.
- login: <enter your Unity ID>
- Password: <enter your Unity password>
- eos%
/mnt/apps/public/CSC/Mysql-Shell/bin/mysql -u your_mysql_acct -p -h classdb2.csc.ncsu.edu
(replace your_mysql_acct with your assigned mysql acct which would match your unity ID) - Note: You can add an alias for the above command using the following steps -
- Edit the file ~/.bash_profile and add the line
alias mysql="/mnt/apps/public/CSC/Mysql-Shell/bin/mysql"
- Save the file, then either open a new Terminal tab, or quit and relaunch Terminal, or refresh the changes by typing
source ~/.bash_profile
- Edit the file ~/.bash_profile and add the line
- Enter password: (this is NOT your unity password. Check with your TA and/or instructor about the assigned password)
MySQL Shell 8.0.25
Copyright (c) 2016, 2021, Oracle and/or its affiliates.
Oracle is a registered trademark of Oracle Corporation and/or its affiliates.
Other names may be trademarks of their respective owners.
Type '\help' or '\?' for help; '\quit' to exit.
Creating a session to 'uid@classdb2.csc.ncsu.edu'
Fetching schema names for autocompletion... Press ^C to stop.
Your MySQL connection id is xxxxx
Server version: 10.5.22-MariaDB MariaDB Server
No default schema selected; type \useto set one.
MySQL classdb2.csc.ncsu.edu:3306 JS >
- At the MySQL classdb2.csc.ncsu.edu:3306 JS > prompt type
\sql
This will switch your command line to SQL instead of JS. - To exit the command line, type
\q
and press Enter.
Changing your MySQL Password
Important: We highly recommend users to change their MySQL passwords ASAP!
- Login to your MySQL acct as explained above.
- MariaDB [(none)]>
SET PASSWORD = password('bla');
replace bla with your new password. Contact csc_help@ncsu.edu to request password reset.
Connecting from Eclipse
Connecting from Eclipse Instructions. (Instructions are under Review)