Marketcetera User FAQ
TracNav menu
-
Marketcetera
-
Overview
- Photon
- ORS
- Tradebase
- OrderLoader
- Virtual Appliance
- User Mailing List
- Download
- License
- Reporting Bugs
-
Documentation
- Marketcetera Platform Configuration
- ORS Guide
- Photon Installation and Configuration
- Photon Guide
- Photon Scripting
- Tradebase Guide
- OrderLoader Guide
- Configuration Files Guide
- Configuring Market Data Feeds
- Order Limits
- Excel Integration
- .NET Support
-
Support
- Support
- User FAQ
- Developer FAQ
-
For Developers
- Architecture
- Building Marketcetera Platform
- Building Photon
- Building Tradebase
- Building Appliance
- Building MarketceteraCOM
- FIX Overview
- Developer Mailing List
- Developer Notes
- Contribute!
- Reading List
- Third-party Dependencies
- Exchange Simulator
- JavaDoc
- Blog
Table of Contents
- I downloaded the ORS and it won't start
- How do I point Marketcetera at my own favorite database?
- How to switch the appliance to a static IP?
- I get "The ORS is currently not logged on" errors in Photon
- ORS is not connecting. What to do?
- Appliance complains about existing mongrel.pid file at start
- How to add a custom message modifier
- My broker deviates from FIX spec. How do I use a custom FIX dictionary?
- ORS on the Appliance refuses to start up
- Clock on the Appliance is off
- Share Classes Support (i.e. BRK/A and BRK/B)
- How do I connect the ORS to my own JMS server?
- How do I configure start/end times for broker sessions?
- How do I reset sequence numbers?
- Changing FIX version of Photon
Note: We highly recommend using the appliance for initial testing and evaluation. It has all the right components (database, libraries, etc) configured correctly which makes testing the Marketcetera Platform a lot easier.
I downloaded the ORS and it won't start
If you downloaded just the ORS and tried running it (with runORS.sh or runORS.bat) the ORS will not work by itself.
The best approach is to examine the ORS log for clues. If the log is not helpful, then just send the entire log to info@marketcetera.com and we'll be happy to examine it and help you out.
By default the ORS logs to a file in <ors_install>/logs/ors.log. You can modify the log4j.properties file to send output to stdout (at line 18) instead of file to see the output in the same window where you start the ORS:
log4j.rootLogger=error,file, stdout
How do I point Marketcetera at my own favorite database?
You can obviously use your own favorite database vendor with the Marketcetera Platform. You just need to be sure that your database satisfies the following compatibility requirements:
- You have a jar for JDBC connectivity through Java
- The database works with Ruby on Rails, currently mysql postgresql sqlite firebird sqlserver db2 oracle sybase openbase frontbase
Most likely your database already fulfills that. Next, follow these steps to point Marketcetera at your database:
- Before you point Marketcetera to your own database, make sure that you have the tables setup as described here.
- Next you need to modify the ORS conf/quickfixj.xml file to modify the sessionSettings bean. You need to modify the following entries accordingly. Keep in mind that JdbcDriver and JdbcUrl are likely to change dramatically.
<entry key="JdbcDriver" value="com.mysql.jdbc.Driver"/> <entry key="JdbcURL" value="jdbc:mysql://localhost/marketcetera"/> <entry key="JdbcUser" value="marketcetera"/> <entry key="JdbcPassword" value="marketcetera"/>
- Be sure to add the jar with the appropriate SQL driver to the lib directory, and modify the startup script to include the new jar
- To point Tradebase at the new database, modify the config/databases.yml file with appropriate values for development and test databases:
adapter: mysql database: marketcetera username: marketcetera password: marketcetera host: 127.0.0.1
How to switch the appliance to a static IP?
The appliance is configured to work with DHCP out of the box. If you want to hard-code a static IP, follow the following steps (largely based on this writeup). Command line commands are prefixed with "%>".
- Remember the password is marketcetera when you are prompted for sudo command
- Use pico (or vi if you are more comfortable) to edit the file. Ctrl-X saves and exits from pico
%> sudo pico /etc/network/interfaces
- At the bottom you will see these lines for the eth0 interface:
auto eth0 iface eth0 inet dhcp
- Replace change the line starting "iface" to read "static" at the end, and add the IP information in the following format.
auto eth0 iface eth0 inet static address 192.168.0.7 netmask 255.255.255.0 network 192.168.0.0 broadcast 192.168.1.255 gateway 192.168.0.1 - Find out what your name server is (either by looking at another computer on same network or asking your network administrator)
- Edit the resolv.conf file to specify the name server
%> sudo vi /etc/resolv.conf
You will need to update (or insert) the line starting with "nameserver" to add the IP address of your preferred nameserver. Here's what ours looks like, with the IP addresses blotted out:
domain marketcetera.com nameserver xxx.xxx.xxx.xxx nameserver xxx.xxx.xxx.xxx
- Restart networking
%> sudo /etc/init.d/networking restart
- Verify that the new address is set
%> ifconfig -a
- Test name resolution by pinging Google (or something else)
%> ping www.google.com
If you get a response, then everything is working.
- If you are still having problems, please try disabling any firewall software that you may have running on the host operating system, and perform the step "Restart networking" again.
I get "The ORS is currently not logged on" errors in Photon
If you are sending orders from Photon and you get The ORS is currently not logged on error in the console, that means that Photon is connected to an ORS, but the ORS itself has not been able to successfully log on to a FIX destination.
If you are connecting to the Marketcetera Exchange Simulator, make sure that you have followed the directions? to register with us and modify the configuration files to specify your particular SenderCompID.
You will then need to restart the ORS, and click on the "Reconnect to ORS" button in Photon to re-establish that connection as well.
If you are still having problem, look at the ORS log files? to see what errors you are getting, and let us know at bugs at marketcetera dot com.
ORS is not connecting. What to do?
Please see the diagnostics section if you are using the Appliance or have the Tradebase running on same machine as the ORS. Otherwise, you can always contact us at bugs at marketcetera dot com
Appliance complains about existing mongrel.pid file at start
If the machine running the Appliance rebooted unexpectedly (say you lost power) or the Appliance did not shutdown properly, you may have an issue with Mongrel starting up because of a leftover mongrel.pid file. To fix the problem, you'll need to log on to the appliance, then delete the file:
cd /opt/marketcetera/tradebase/log/ sudo rm mongrel.pid sudo /etc/init.d/mongrel start
That should take care of deleting the file and restarting mongrel. Use your marketcetera user password if it asks you for one.
How to add a custom message modifier
While it's fairly simple to add custom fields? to outgoing FIX messages using the basic message modifier, sometimes you need to do something more complicated. See this writeup on how to create custom message modifiers. You can also add default custom fields through Photon as well.
My broker deviates from FIX spec. How do I use a custom FIX dictionary?
Not all brokers FIX implementations are created equal, and as a result everybody has slight deviations from the FIX spec. Some brokers choose to back-port FIX.4.4 fields into FIX.4.2 messages, others add custom fields to an existing message or create completely new messages.
Thankfully, Quickfix/J provides for a way to specify a custom FIX data dictionary file for message validation. See the writeup on how to specify a custom data dictionary or just modify the fixDictionaryPath bean in the ORS.xml file if you already know what you are doing:
<bean id="fixDictionaryPath" class="java.lang.String"> <constructor-arg value="FIX42-brokerA.xml"/> </bean>
ORS on the Appliance refuses to start up
Sometimes when you modify the networking on the appliance (switch from Bridged to NAT or vice versa, update Windows drivers, etc) the networking on the VMWare appliance and underlying Ubuntu gets really confused. If you are in a situation when the ORS just won't start up after you restart the appliance, or you see that "marketcetera" host doesn't resolve in the sanityCheck.rb script, then take a look at your /etc/hosts file. Make sure that the line with marketcetera host on it has a valid IP address. If it doesn't, modify it to have the same address as the output of ifconfig, and restart the ORS using sudo /etc/init.d/ORS start.
You may also need to read this writeup for additional information.
Clock on the Appliance is off
Sometimes when you suspend the VMWare Player with the appliance for long periods of time, it is possible for the appliance clock to be way behind the next time it starts up. This is a known problem and we are working to solve it. If your Tradebase diagnostics page (or the status command at login prompt) shows that the clock is off, here's what you need to do:
- Login to the appliance with marketcetera/marketcetera
- Shut down NTP (network time protocol)
- Manually set the clok
- Restart NTP
You can accomplish it with these commands. Remember to use the marketcetera user's password when prompted:
sudo /etc/init.d/ntp stop sudo ntpdate ntp.ubuntu.com sudo /etc/init.d/ntp start
The ORS should be able to connect to your destination. If you are impatient, you can "nudge" it by restarting the ORS with the following command:
sudo /etc/init.d/ORS restart
Share Classes Support (i.e. BRK/A and BRK/B)
Since some shares are more equal than others, Marketcetera can be configured to automatically split the suffix of different share classes. See the writeup on how to configure share classes? support.
How do I connect the ORS to my own JMS server?
Currently the ORS starts up with an embedded JMS Broker (ActiveMQ) that listens on port 61616. The start parameters for the embedded ActiveMQ instance are specified in the broker.xml configuration file, and both the ORS and OrderLoader specify their connections to it via the connectionFactory bean in their respective configuration files. You can easily point both the ORS and OrderLoader to a different message queue by modifying the following beans:
<bean id="connectionFactory" class="org.apache.activemq.ActiveMQConnectionFactory"> <property name="brokerURL" value="tcp://<machine>:<port>"/> </bean>
See the JMS configuration section for more information.
If you are using Tradebase, you need to make sure that your instance of JMS supports the STOMP protocol and modify the <tradebase>/conf/broker.yml file to point to your instance of JMS server.
How do I configure start/end times for broker sessions?
Many brokers turn off their FIX engines after the market closes, and start accepting connections again right before the market opens. You can modify that behaviour in the quickfixj.xml using the constants specified in the QuickFIX/J configuration section. Here's an example setup that keeps the FIX session open from Sunday 4:57pm to Friday 5:03pm Eastern:
<entry key="StartTime" value="04:57:00 US/Eastern"/> <entry key="StartDay" value="Sunday"/> <entry key="EndTime" value="17:03:00 US/Eastern"/> <entry key="EndDay" value="Friday"/> <entry key="TimeZone" value="America/New_York"/>
How do I reset sequence numbers?
See the writeup on how to change sequence numbers for more information.
Changing FIX version of Photon
You can change the FIX version that Photon runs as by creating a custom initialization file and specifying that when you start Photon. Create the my.ini file in the same directory as photon.exe with the following content:
org.marketcetera.photon/fix.version=FIX43
This specifies FIX 4.3 as the version, you can use FIX44, FIX41, etc. Then, start Photon manually from command-line specifying the custom .ini file:
photon-dir:> photon.exe -pluginCustomization my.ini
When you look at the FIX message details, you should see that Photon is now sending FIX 4.3 messages out.
