Ubuntu Servers :: Adding Foreign Key Using MySQL Administrator Fails / Fix It?
Aug 27, 2010
I want to setup my MySQL database and have MySQL up and running. I sill look for a good editor to add and configure my tables, it appears that MySQL Administrator is the only GUI client available.
But when I try to add a foreign key to one of my tables, there appears to be a problem. Both of my tables are InnoDB and both have a primary key.
-First I choose the tab "Foreign Keys" on my CLIENT table.
-Then I press the green + sign to add a foreign key, it is default named new_fk_constraint.
-I choose my table USER in the Refer.Table dropdownbox
-And then I should be able to match the FK field and the PK field in the box on the right... but this box is empty. Double clicking shows nothing. I only can drag the user_id of the USER table to it, but have no option to select the foreign column.
What the hell is wrong here??? This client is years old and should be really REALLY working IMHO! I was told by a friend that there is no good client available and therefore he is using some Windows program for this...
I have install mysql on my fedora12. My different mysql server is located in us. I want to check health status and hits per seconds everything. Is it possible with mysql-administrator command.
now a these days i am connect through ssh and excuting below command
#mytop mysql -u root -p <passwd>
In my mysql db i have added the userip & passwd (allowed the privileages for that ip)
If i use mysql-administrator i am getting below error
MySQL Error Nr. 2003 Can't connect to MySQL server on '66.98.152.64' (111)
I'm trying to start my MySQL server, and it fails if the /etc/mysql/my.cnf file is there. If it isn't, then it fails - syslog shows me this:
Code: Jun 5 11:02:53 myhost /etc/init.d/mysql[21733]: 0 processes alive and '/usr/bin/mysqladmin --defaults-file=/etc/mysql/debian.cnf ping' resulted in Jun 5 11:02:53 myhost /etc/init.d/mysql[21733]: #007/usr/bin/mysqladmin: connect to server at 'localhost' failed
I've just upgraded to 9.10, and mysql fails to start. When I do an /etc/init.d/mysql start, I just get * Starting MySQL database server mysqld ...fail!with no additional errors or information to say what went wrong. I saw this thread http://ubuntuforums.org/showthread.php?t=1322070 but the fix mentioned does not apply, as I don't have the #skip bsd line in my config file.
I want to use MYSQL administrator remotely, if I try I just get Host 192.168.1.216 is not allowed to connect to this mysql server. All the fixes I see on the Internet are for specific databases, but I want to access everything?
what is wrong with this SQL to create a stored procedure in MySQL please?
Code:
CREATE DEFINER=`root`@`localhost` PROCEDURE `CheckStatus`( IN start_date DATE, IN end_date DATE) BEGIN
[code]...
To me the syntax is correct. It complains with error 1327 'Undeclared variable: temp_sales'. What I don't understand is why I would need to declare a temporary table's name as a variable. Am I missing something here?
I performed a F13 to F14 upgrade today and it went very well. The only problem I'm having is that I can longer Telnet to the machine.The client side returns a "connection closed by foreign host" message or "connection to host lost", depending on the client.The /var/log/messages file contains "FATAL: bad tty" following every telnet attempt.I receive the same error even when trying to telnet to localhost on the local machine.
Need help maintaining permissions across multiple directories. Have Ubuntu 8.04 Hardy Heron. O/S installed, updated and running with no problems.Why is it that my administrator user id doesn't seem to have root permissions to create directories? I am trying to setup hosting 3 separate websites and therefore create 3 separate directories to manage all associated files for the 3 websites. Also, I am attempting to read through the tutorials located at:URL...
I have installed Mysql in Ubuntu 9, for the use of roundcube database.After installing iam getting the error like this
* Stopping MySQL database server mysqld [ OK ] * Starting MySQL database server mysqld [ OK ] * Checking for corrupt, not cleanly closed and upgrade needing tables.
So because of this in the roundcube configuration its giving the error message that MYSQL is not installed. So Kindly give me a idea how to solve this.
I'm interested in finding out, specifically, what causes daemon's to be shutdown when I shutdown Ubuntu? I'm use Ubuntu which is why I'm posting here, but I suppose this knowledge could apply to other Disto's too. Perhaps I'm better off to explain with an example:
I wrote a C++ that queries a Mysql database. I want it to run every time the computer is shutdown. I've verified the program works fine, and I've verified that I can run a program on shutdown of the computer by putting it in /etc/rc0.d. The problem is that by the time rc0.d runs my program, mysql has already been shutoff, and it can't connect.
So what I'm wondering is, is there a script or something at a higher level that goes around turning things like daemons as the System shutdowns, but before any of the scripts in rc0.d are run? (It doesn't look like anything in here is shutting down mysql). Something that actually calls mysql shutdown? How I can add my program to be run before mysql shuts down.
Otherwise, I might end up having to get the source code compile by own /sbin/shutdown and tweak it from there. Granted I might end up doing this anyway because there's more stuff I want to customize during shutdown (e.g. abort it under certain conditions), but I'm hoping not to go that far just yet.
I have the following mysql query which works great.
Code: SELECT msg FROM `logs` WHERE ((`host` = 'aaa.bbb.ccc.ddd') OR (`host` = 'aaa.bbb.ccc.ddd')) AND `msg` REGEXP CONVERT( _utf8 'physical addresses' USING latin1 ) COLLATE latin1_swedish_ci I need to refine this query so that I can query the last # hours using the `datetime` field in the database. I have researched the DATE_SUB function and can query for example the last 1 hour like this:
I have cpanel running and working with mysql. I need to add ODBC so I can get server side action script to connect to mysql also. Will adding ODBC affect anything else? I don't want to affect the way anything else connects?
I am trying to install Koha on centos5.5. Afte installing myqsl it starts normally. But when i add following lines into my.cnf and trying to restart mysql again it says that restart is failed.
here is the lines that i add into [mysqld] section
When I try to add software sources (specifically those for Scratchbox, but I get the same error with everything), I get an error message: "http://http not found". Obviously that is not a valid APT line and I have no idea what it is doing in my software sources. How do I take it out?
I am trying to modify the source code of a C application (quagga) in order to insert data into a mysql table. I have added 2 new source files to the source (neto_mysql, neto_trend) which in turn use mysql.h. I have also modified the Makefile.am file to include the /usr/include/mysql directory.
When trying to compile, i get the following error. What am I missing? I have minimal experience with formal C applications like this. I feel like I may also have to include the mysql.h file in the libbgp? I dont understand why it cant find the mysql functions...
I've just installed debian to a thumb drive on a system with no hard drives. I did not install any hard drive to avoid confusion. The installation went well, I rebooted the system several times with no issues until I decided to install the hard drive (SATA drive). After I installed the hard drive the system failed to boot showing something like:
Code: Decompressing Linux... Parsing ELF... done. Booting the kernel. Loading, please wait... mount: mounting /dev/sda1 on /root failed: No such device (continues for other partitions and mount points) Target filesystem doesn't have /sbin/init No init found. Try passing init=bootarg
BusyBox v1.10.2 (Debian 1:1.10.2-2) built-in shell (ash) /bin/sh: can't access tty; job control turned off (initramfs) [9.670347] sd 0:0:0:0: [sdb] Assuming drive cache: write through [9.673805] sd 0:0:0:0: [sdb] Assuming drive cache: write through (some insignificant text was not copied :P)
I am guessing that the new disk is somehow confusing debian regarding where to look for system files or the address where the devices are located because if I remove the data cable from the hard drive the system reboots correctly (no hard drive though). Hotpluging the drive works but once I reboot it happens again.
I've installed MySQL-server-community-5.1.35-0.rhel5.x86_64.rpm, client and devel on my 64 bit server having CentOS 5.4 (Final) as operating system. Now when I setup my.cnf file and add an entry "init-file=/usr/src/script.sql" and restart Mysql service then Mysql fails to start but when I comment init-file portion in my.cnf file then mysql runs fine. Please find below log file entry in mysql log
100304 3:03:38 [ERROR] /usr/sbin/mysqld: File '/usr/src/scripts/startup.sql' not found (Errcode: 13) 100304 3:03:38 [ERROR] Aborting
I have verified that file exist on the location mentioned in my.cnf file. Can anybody please suggest fix of this problem.
Im having a major problem with mysql-server failing to install.The installation stoppes on "Running Transactions" (have tried waiting for 10 minutes). When I use Ctrl+C an error appears:error: %pre(mysql-server-5.0.77-4.el5_5.4.x86_64) scriptlet failed, signal 2 error: install: %pre scriptlet failed (2), skipping mysql-server-5.0.77-4.el5_5.4
I am trying to get mysql to start at boot without any success.
The mysqld scripts works fine when run from the command line, but it does not work when i use the links created by chkconfig. I checked the boot.log and found that mysql starts but then it stops or gets shutdown. This is the log message:
Starting mysqld daemon with databases from /data/mysql [ OK ] Starting cups: [ OK ] STOPPING server from pid file /var/run/mysqld/mysqld.pid starting DenyHosts: /usr/bin/denyhosts.py --daemon --config=/usr/share/denyho sts/denyhosts.cfg 090727 04:35:47 mysqld ended
I got assigned to a project, where the installation is done over ansible. As I'm new in linux, python, django, ansible I wanted to try this out on a empty linux debian.
Code: Select alluname -a
Linux DebianABC 3.16.0-4 amd64 #1 SMP Debian 3.16.7-ckt20-1+deb8u4 (2016-02-29) x86 64 Gnu/Linux
When I now run my ansible playbook it tries to install mysql and suddenly I get an error:
Code: Select all:stderr: DEPRECATION: --allow-external has been deprecated and will be removed in the future. Due to changes in the repository protocol, it no longer has any effect.
DEPRECATION: --allow-unverified has been deprecated and will be removed in the future. Due to changes in the repository protocol, it no longer has any effect.
Could not find a version that satisfies the requirement mysql-connector-python==1.0.12 (from -r /home/abc/abcTest/requirements.pip (line 36)) (from versions: )
No matching distribution found for mysql-connector-python==1.0.12 (from -r /home/abc/abcTest/requirements.pip (line 36))
My MySQL replication slave failed,while reading a large size table from master.Thhe information from error.logError 'Unknown table engine 'InnoDB'' on query. Default database: 'test'. Query: I am sure that table is a Big size table..
I've recently installed a RedHat Enterprise Linux server and am attempting to get PHP/MySQL installed on it. It cannot load the dynamic php mysql module, giving me an error (in /var/log/error_log) that reads as follows:
PHP Warning: PHP Startup: Unable to load dynamic library '/usr/lib/php/modules/mysql.so' - /usr/lib/php/modules/mysql.so: undefined symbol: executor_globals in Unknown on line 0
(In fact, it fails to load ALL of the dynamic php modules, either with the "undefined symbol: executor_global" or "undefined symbol: core_globals" I DO NOT WANT to compile anything -- I want to stay with stock RedHat released software.
[root@hostname-suppressed httpd]# uname -a Linux hostname-suppressed 2.6.18-194.17.4.el5PAE #1 SMP Wed Oct 20 13:13:33 EDT 2010 i686 athlon i386 GNU/Linux [root@hostname-suppressed httpd]# cat /etc/redhat-release Red Hat Enterprise Linux Server release 5.5 (Tikanga)
This probably sounds like a stupid question, but I need to add a NIC to an existing server running Ubuntu Server edition 8.10. My question is what changes I need to make once the NIC is physically installed? I guess it will not be autoconfigured, so I will have to add it to the /etc/network/interfaces manually, which is ok as I need to set it up with a static interface anyway.Is there a good How-to or set of instructions on how to do this?
I'm trying to switch over my old server(9.10) data to a different server(10.04). My old server only had 2 drive bays, whereas my new one has 4. I already have my new server up and running(for the most part), and want to add the old hard drive to it. How would I do this without losing any information. I believe even my old drive is formatted to ext4. I was going to just throw it in there, but I'm afraid of losing information as I really don't want to lose a 1tb of info. I did try to search, but my title had too many common words in it.
I currently have an Ubuntu Server setup with a CF card that has / and /boot on their own partitions. I also have a single 1TB drive that is dedicated to the /home partition, however it's a drive that I have run out of space on.
I just purchased a 1.5TB drive to throw in the server, but I am not sure how to set this drive up so that it's seamlessly integrated with the 1TB drive. I would like it setup so that my /home partition is expanded from 1Tb to 2.5TB. I know what I am explaining is similar to raid 0, of which I am not opposed to, except that everything I have searched for online solely explains a raid setup during installation, and I don't have the time (due to school) to reinstall and reconfigure my system.
So in a nutshell, is there a way to setup raid 0 without doing a re-install or is there a way to setup 'fstab' to accomadate my request?
I need some help on this one. I added an second internal hard drive to my file server, a 500GB WD. I want to use this drive as the primary storage drive for my file server, and I want to format it with XFS. I've found some guides showing me how to add hard drives, but they didn't really fit what I want to do. When I run fdisk -l this is what I get
Code:
Disk /dev/sda: 120.0 GB, 120034123776 bytes 255 heads, 63 sectors/track, 14593 cylinders Units = cylinders of 16065 * 512 = 8225280 bytes Disk identifier: 0x0001af4f
[code]....
Disk /dev/sdb doesn't contain a valid partition table