Search Results

Search found 2401 results on 97 pages for 'routing'.

Page 14/97 | < Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >

  • How can I use dynamic routing with openvpn tunnels?

    - by pQd
    i'm thinking about using dynamic routing [ OSPF or RIP ] via OpenVPN tunnels. right now i have few offices connected in full mesh, but this is not scalable solution as we add more locations. i would like to avoid situation when plenty of internal traffic is affected if one of two vpn termination points that i plan to use is down. do you have similar configuration working in production? if so - what routing daemon did you use - quagga? something else? did you encounter any problems? thanks!

    Read the article

  • Routing traffic to specific web sites through Ethernet, rest via wifi on Mac OS X 10.6?

    - by user32448
    Hi I have two separate Internet connections connected to a Mac and I'd like one of them (via Ethernet eth0 gateway 192.168.2.1) to serve for just backing up to an remote online storage, and the other one (via Airport en1 gateway 192.168.1.1) for all other Internet traffic. I tried using "route" from the terminal as follows: sudo route add -host 98.207.226.113 -interface eth0 (just for testing against the site www.whatismyip.org whose IP is 98.207.226.113, to see through which gateway the traffic is routed) I can see using netstat that the route is added: $ netstat -rn -f inet Routing tables Internet: Destination Gateway Flags Refs Use Netif Expire default 192.168.1.1 UGSc 49 0 en1 98.207.226.113 192.168.2.1 UGSc 0 0 eth0 However, the traffic in this case does NOT get routed properly through Ethernet, as if the routing definition I made is ignored. Any ideas? Thanks!

    Read the article

  • ViewContext.RouteData.Values["action"] is null on server... works fine on local machine

    - by rksprst
    I'm having a weird issue where ViewContext.RouteData.Values["action"] is null on my staging server, but works fine on my dev machine (asp.net development server). The code is simple: public string CheckActiveClass(string actionName) { string text = ""; if (ViewContext.RouteData.Values["action"].ToString() == actionName) { text = "selected"; } return text; } I get the error on the ViewContext.RouteData.Values["action"] line. The error is: Exception Details: System.NullReferenceException: Object reference not set to an instance of an object. Any help is appreciated. Thanks in advance.

    Read the article

  • Call named routes in CakePHP as the same way in Ruby on Rails

    - by Lucas Renan
    How can I call a route (in the view) in CakePHP as the same way in Rails? Ruby on Rails routes.rb map.my_route '/my-route', :controller => 'my_controller', :action => 'index' view link_to 'My Route Name', my_route_path CakePHP routes.php Router::connect('/my-route', array('controller' => 'my_controller', 'action' => 'index')); view $html->link('My Route Name', '/my-route'); But I think the Rails way is better, because I can make changes in the "url" and I don't need changes the code of the views.

    Read the article

  • ASP.Net MVC: "Random" URLs getting generated by URL.Action

    - by Daniel Magliola
    I have 2 very similar routes, just because i'm trying to generate two different URLs for the same resource (same Controller/Action), and both are very similar. These are the routes definitions: routes.MapRoute("Post2.Mp3", "sites/{siteSlug}/post/{brand}/aconstant-{slug}.mp3", new { controller = "Posts", action = "Mp3" }, new { siteSlug = @"[A-Za-z0-9-_]+", slug = @"[^(aconstant\-)][A-Za-z0-9-_]+", brand = @"[A-Za-z0-9-_]+" }); routes.MapRoute("Post.Mp3", "sites/{siteSlug}/post/{slug}.mp3", new { controller = "Posts", action = "Mp3" }, new { siteSlug = @"[A-Za-z0-9-_]+", slug = @"[A-Za-z0-9-_]+" }); "brand" is going to be my site name, which is the same as "aconstant" in those routes. Now, if I try this: Url.Action("ShowMp3", "Posts", new { siteSlug = post.Site.Slug, slug = post.Slug, origin = "origfeedwithaudio", brand = "aconstant" }) sometimes I get the URL I expect: /sites/site-Name/post/aconstant/aconstant-post-Name.mp3 but sometimes, I get this: /sites/site-Name/post/post-Name.mp3?brand=aconstant By sometimes, I mean that different sets of "slugs" give me one or the other. I haven't seen the same set of slugs give me different URLs. I haven't found any reasonable rule for when i'm getting one or the other, it seems random. What is going on here? How can I be getting different URLs based on esentially the same arguments? Thanks! Daniel

    Read the article

  • router connect configuration in cakephp 1.3

    - by Gaurav Sharma
    Hello everyone, I have defined the following rule in the router.php file of my cakephp 1.3 based application Router::connect('/tags/*',array('plugin' => 'tags', 'controller' => 'Tags', 'action' => 'index', 'admin' => false)); I have used the tags plugin. When I display the tags related to a topic then the URL on the tags appears something like this http://localhost/testapp/tags/Tags/view/{tag_key_name} I want to make this url for any action to tags plugin like this http://localhost/testapp/Tags/{action}/{tag_key_name} for (view, admin_view and admin_edit) and http://localhost/testapp/Tags/{action} for (index, admin_index and any other action that does not require an id or keyname for execution)

    Read the article

  • How test that ASP.NET MVC route redirects to other site?

    - by Matt Lacey
    Due to a prinitng error in some promotional material I have a site that is receiving a lot of requests which should be for one site arriving at another. i.e. The valid sites are http://site1.com/abc & http://site2.com/def but people are being told to go to http://site1.com/def. I have control over site1 but not site2. site1 contains logic for checking that the first part of the route is valid in an actionfilter, like this: public override void OnActionExecuting(ActionExecutingContext filterContext) { base.OnActionExecuting(filterContext); if ((!filterContext.ActionParameters.ContainsKey("id")) || (!manager.WhiteLabelExists(filterContext.ActionParameters["id"].ToString()))) { if (filterContext.ActionParameters["id"].ToString().ToLowerInvariant().Equals("def")) { filterContext.HttpContext.Response.Redirect("http://site2.com/def", true); } filterContext.Result = new ViewResult { ViewName = "NoWhiteLabel" }; filterContext.HttpContext.Response.Clear(); } } I'm not sure how to test the redirection to the other site though. I already have tests for redirecting to "NoWhiteLabel" using the MvcContrib Test Helpers, but these aren't able to handle (as far as I can see) this situation. How do I test the redirection to antoher site?

    Read the article

  • Creating an Admin directory in Rails

    - by matsko
    I've been developing the CMS backend for a website for a few weeks now. The idea is to craft everything in the backend first so that it can manage the database and information that will be displayed on the main website. As of now, I currently have all my code setup in the normal rails MVC structure. So the users admin is /users and videos is /videos. My plans are to take the code for this and move it to a /admin directory. So the two controllers above would need to be accessed by /admin/users and /admin/videos. I'm not sure how todo the ruote (adding the /admin as a prefix) nor am I sure about how to manage the logic. What I'm thinking of doing is setting up an additional 'middle' controller that somehow gets nested between the ApplicationControler and the targetted controller when the /admin directory is accessed. This way, any additional flags and overloaded methods can be spawned for the /admin section only (I believe I could use a filter too for this). If that were to work, then the next issue would be separating the views logic (but that would just be renaming folders and so on). Either I do it that way or I have two rails instances that share the MVC code between them (and I guess the database too), but I fear that would cause lots of duplication errors. Any ideas as to how I should go about doing this? Many thanks!

    Read the article

  • Why doesn't a URL with two hyphens ( in one segment ) match a Route in my Route Table?

    - by Atomiton
    I'm trying to resolve this URL Route: Route articlesByCategory = new Route("articles/c{cid}-{category}", new Handler); However, it seems like the following url won't resolve to this route: // doesn't work www.site.com/articles/c24-this-is-the-category-title // This works www.site.com/articles/c24-category I assume it has to do with the dashes in the title, but can anyone tell me why this works this way? Is there a way to allow dashes in the title for a URL route like this?

    Read the article

  • Why doesn't a URL Route with two dashes resolve?

    - by Atomiton
    I'm trying to resolve this URL Route: Route articlesByCategory = new Route("articles/c{cid}-{category}", new Handler); However, it seems like the following url won't resolve to this route: // doesn't work www.site.com/articles/c24-this-is-the-category-title // This works www.site.com/articles/c24-category I assume it has to do with the dashes in the title, but can anyone tell me why this works this way? Is there a way to allow dashes in the title for a URL route like this?

    Read the article

  • Generic ASP.NET MVC Route Conflict

    - by Donn Felker
    I'm working on a Legacy ASP.NET system. I say legacy because there are NO tests around 90% of the system. I'm trying to fix the routes in this project and I'm running into a issue I wish to solve with generic routes. I have the following routes: routes.MapRoute( "DefaultWithPdn", "{controller}/{action}/{pdn}", new { controller = "", action = "Index", pdn = "" }, null ); routes.MapRoute( "DefaultWithClientId", "{controller}/{action}/{clientId}", new { controller = "", action = "index", clientid = "" }, null ); The problem is that the first route is catching all of the traffic for what I need to be routed to the second route. The route is generic (no controller is defined in the constraint in either route definition) because multiple controllers throughout the entire app share this same premise (sometimes we need a "pdn" sometimes we need a "clientId"). How can I map these generic routes so that they go to the proper controller and action, yet not have one be too greedy? Or can I at all? Are these routes too generic (which is what I'm starting to believe is the case). My only option at this point (AFAIK) is one of the following: In the contraints, apply a regex to match the action values like: (foo|bar|biz|bang) and the same for the controller: (home|customer|products) for each controller. However, this has a problem in the fact that I may need to do this: ~/Foo/Home/123 // Should map to "DefaultwithPdn" ~/Foo/Home/abc // Should map to "DefaultWithClientId" Which means that if the Foo Controller has an action that takes a pdn and another action that takes a clientId (which happens all the time in this app), the wrong route is chosen. To hardcode these contstraints into each possible controller/action combo seems like a lot of duplication to me and I have the feeling I've been looking at the problem for too long so I need another pair of eyes to help out. Can I have generic routes to handle this scenario? Or do I need to have custom routes for each controller with constraints applied to the actions on those routes? Thanks

    Read the article

  • ASP.NET MVC Default URL View

    - by Moose Factory
    I'm trying to set the Default URL of my MVC application to a view within an area of my application. The area is called "Common", the controller "Home" and the view "Index". I've tried setting the defaultUrl in the forms section of web.config to "~/Common/Home/Index" with no success. I've also tried mapping a new route in global.asax, thus: routes.MapRoute( "Area", "{area}/{controller}/{action}/{id}", new { area = "Common", controller = "Home", action = "Index", id = "" } ); Again, to no avail.

    Read the article

  • In Ruby on Rails, routes.rb, if map.something will create something_path and something_url, does map

    - by Jian Lin
    In Ruby on Rails, routes.rb, if we create a "named route" map.something ":a/:b", :controller => 'foobar' it will also create something_path and something_url which are two methods usable in the controller and in the view. Does map.connect create something like that too? Otherwise, isn't map.connect somewhat disadvantaged in this way? I checked that connect_path and connect_url both aren't created automatically.

    Read the article

  • ASP.NET MVC Route based on Web Browser/Device (e.g. iPhone)

    - by Alex
    Is it possible, from within ASP.NET MVC, to route to different controllers or actions based on the accessing device/browser? I'm thinking of setting up alternative actions and views for some parts of my website in case it is accessed from the iPhone, to optimize display and functionality of it. I don't want to create a completely separate project for the iPhone though as the majority of the site is fine on any device. Any idea on how to do this?

    Read the article

  • Web Forms Routing not having correct path to images, css, scripts ...

    - by feronovak
    Hello, I am trying to use new .net 4.0 Routing for Web Forms with mixed success. protected void Application_Start(object sender, EventArgs e) { RegisterRoutes(RouteTable.Routes); } public static void RegisterRoutes(RouteCollection routes) { routes.MapPageRoute( "", "article/{id}/{title}", "~/ar.aspx", true, new RouteValueDictionary{{"id", "[0-9]*"}, {"title", ""}} ); } Routing as such works well on a local machine as well as a remote server. However, I am unable to find out how to set up routing in such a way that server ignores routing for images, css and scripts so it will be read as http://address/css/text.css instead of http://address/article/1212/some-text/css/text.css The only way I can make this work if I put tag into but I am sure it can be done other way. I would appreciate any help on this topic. Fero

    Read the article

  • How to configure a URL with 3 levels in ASP.NET MVC?

    - by MCardinale
    Using ASP.NET MVC, I need to configure my URLs like this: www.foo.com/company : render View Company www.foo.com/company/about : render View Company www.foo.com/company/about/mission : render View Mission If "company" is my controller and "about" is my action, what should be "mission"? For every "folder" (company, about and mission) I have to render a different View. Anyone knows how can I do that? Thanks!

    Read the article

  • How broken is routing strategy that causes a martian packet (so far only) during tracepath?

    - by lkraav
    I believe I've achieved a table that routes packets from and to eth1/192.168.3.x through 192.168.3.1, and packets from and to eth0/192.168.1.x through 192.168.1.1 (helpful source). Question: when doing tracepath from 192.168.3.20 (from within vserver), I'm getting kernel: [318535.927489] martian source 192.168.3.20 from 212.47.223.33, on dev eth0 at or near the target IP, while intermediary hops go without (log below). I don't understand why this packet is arriving on eth0, instead of eth1, even after reading this: Note that you may see packets from non-routable IP addresses when running the traceroute or tracepath commands. While packets cannot be routed to these routers, packets sent between 2 routers only need to know the address of the next hop within the local networks, which could be a non-routable address. Can someone explain that paragraph in human language? Based on short initial trials so far, everything else seems to work without causing martians. Is this contained to the nature of tracepath operation or do I have some other bigger routing problem that will cause work traffic breakage? Side note: is it possible to inspect martian packet with tcpdump or wireshark or anything of the sort? I'm have not been able to get it to show up on my own. vserver-20 / # tracepath -n 212.47.223.33 1: 192.168.3.2 0.064ms pmtu 1500 1: 192.168.3.1 1.076ms 1: 192.168.3.1 1.259ms 2: 90.191.8.2 1.908ms 3: 90.190.134.194 2.595ms 4: 194.126.123.94 2.136ms asymm 5 5: 195.250.170.22 2.266ms asymm 6 6: 212.47.201.86 2.390ms asymm 7 7: no reply 8: no reply 9: no reply ^C Host routing: $ sudo ip addr 1: lo: <LOOPBACK,UP,LOWER_UP> mtu 16436 qdisc noqueue state UNKNOWN link/loopback 00:00:00:00:00:00 brd 00:00:00:00:00:00 inet 127.0.0.1/8 scope host lo 2: sit0: <NOARP> mtu 1480 qdisc noop state DOWN link/sit 0.0.0.0 brd 0.0.0.0 3: eth0: <BROADCAST,MULTICAST,PROMISC,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000 link/ether 00:24:1d:de:b3:5d brd ff:ff:ff:ff:ff:ff inet 192.168.1.2/24 scope global eth0 4: eth1: <BROADCAST,MULTICAST,PROMISC,UP,LOWER_UP> mtu 1500 qdisc pfifo_fast state UP qlen 1000 link/ether 00:0c:46:46:a3:6a brd ff:ff:ff:ff:ff:ff inet 192.168.3.2/27 scope global eth1 inet 192.168.3.20/27 brd 192.168.3.31 scope global secondary eth1 # linux-vserver instance $ sudo ip route default via 192.168.1.1 dev eth0 metric 3 unreachable 127.0.0.0/8 scope host 192.168.1.0/24 dev eth0 proto kernel scope link src 192.168.1.2 192.168.3.0/27 dev eth1 proto kernel scope link src 192.168.3.2 $ sudo ip rule 0: from all lookup local 32764: from all to 192.168.3.0/27 lookup dmz 32765: from 192.168.3.0/27 lookup dmz 32766: from all lookup main 32767: from all lookup default $ sudo ip route show table dmz default via 192.168.3.1 dev eth1 metric 4 192.168.3.0/27 dev eth1 scope link metric 4 Gateway routing # ip route 10.24.0.2 dev tun0 proto kernel scope link src 10.24.0.1 10.24.0.0/24 via 10.24.0.2 dev tun0 192.168.3.0/24 dev br-dmz proto kernel scope link src 192.168.3.1 192.168.1.0/24 dev br-lan proto kernel scope link src 192.168.1.1 $ISP_NET/23 dev eth0.1 proto kernel scope link src $WAN_IP default via $ISP_GW dev eth0.1 Additional background Options for non-virtualized network interface isolation?

    Read the article

  • BizTalk: Sample: Context routing and Throttling with orchestration

    - by Leonid Ganeline
    The sample demonstrates using orchestration for throttling and using context routing. Usually throttling is implemented on the host level (in BizTalk 2010 we can also using the host instance level throttling). Here is demonstrated the throttling with orchestration convoy that slows down message flow from some customers. Sample implements sort of quality service agreement layer for different kind of customers. The sample demonstrates the context routing between orchestrations. It has several advantages over the content routing. For example, we don’t have to create the property schema and promote properties on the schemas; we don’t have to change the message content to change routing. Use case:  The BizTalk application has a main processing orchestration that process all input messages. The application usually works as an OLTP application. Input messages came in random order without peaks, typical scenario for the on-line users. But sometimes the big data batch payloads come. These batches overload processing orchestrations. All processes, activated by on-line users after the payload, come to the same queue and are processed only after the payload. Result is on-line users can see significant delay in processing. It can be minutes or hours, depending of the batch size. Requirements: On-line user’s processing should work without delays. Big batches cannot disturb on-line users. There should be higher priority for the on-line users and the lower priority for the batches. Design: Decision is to divide the message flow in two branches, one for on-line users and second for batches. Branch with batches provides messages to the processing line with low priority, and the on-line user’s branch – with high priority. All messages are provided by hi-speed receive port. BTS.ReceivePortName context property is used for routing. The Router orchestration separates messages sent from on-line users and from the batch messages. But the Router does not use the BizTalk provided value of this property, the Router set up this value by itself. Router uses the content of the messages to decide if it is from on-line users or from batches. The message context property the BTS.ReceivePortName is changed respectively, its value works as a recipient address, as the “To” address for the next recipient orchestrations. Those next orchestrations are the BatchBottleneck and the MainProcess orchestrations. Messages with context equal “ToBatch” are filtered up by the BatchBottleneck orchestration. It is a unified convoy orchestration and it throttles the message flow, delaying the message delivery to the MainProcess orchestration. The BatchBottleneck orchestration changes the message context to the “ToProcess” and sends messages one after another with small delay in between. Delay can be configured in the BizTalk config file as:                 <appSettings>                                 <add key="GLD_Tests_TwoWayRouting_BatchBottleneck_DelayMillisec" value="100"/>                 </appSettings>   Of course, messages with context equal “ToProcess” are filtered up by the MainProcess orchestration.   NOTES: Filters with string values: In Orchestrations (the first Receive shape in orchestration) use string values WITH quotes; in Send Ports use string values WITHOUT quotes. Filters on the Send Ports are dynamic; we can change them in run-time. Filters on the Orchestrations are static; we can change them only in design-time. To check the existence of the promoted property inside orchestration use the Expression shape with construction like this:       if (BTS.ReceivePortName exists myMessage) { …; } It is not possible in the Message Assignment shape because using the “if” statement inside Message Assignment is prohibited. Several predefined context properties can behave in specific way. Say MessageTracking.OriginatingMessage or XMLNORM.DocumentSpecName, they are required some internal rules should be applied to the format or usage of this properties. MessageTracking.* parameters require you have to use tracking and you can get unexpected run-time errors in some cases. My recommendation is - use very limited set of the predefined context properties. To “attach” the new promoted property to the message, we have to use correlation. The correlation type should include this property. [Here is a good explanation by Saravana ] The sample code is here [sorry, temporary trubles with CodePlex].

    Read the article

  • Routing multiple static IPs from ISP at the cable modem?

    - by Jakobud
    I'm taking over IT responsibilities for a previous IT guy. We have a 50mb cable modem connection from Comcast along with 5 static IP addresses: XXX.XXX.XXX.180 XXX.XXX.XXX.181 XXX.XXX.XXX.182 XXX.XXX.XXX.183 XXX.XXX.XXX.184 We are in the process of replacing our firewall machine. Currently the firewall box is the only thing connected to the cable modem. However the cable modem has multiple ethernet ports on it, similarly to a router. I have assembled a new firewall machine and its time to start testing and configuring it. So that means that I also need it plugged into the cable modem (remember it has multiple ethernet ports on it). So now with multiple computer plugged into the cable modem, how does the cable modem know where to route the traffic? If some request on the internet is made to XXX.XXX.XXX.181, which goes to our cable modem, how does the cable modem know which connected computer that traffic is supposed to be sent? Looking at the web interface for the cable modem, there doesn't seem to be anything special setup on it with regards to routing or NATing IP addresses. Is that because when there is only one computer connected to the modem, all traffic is sent to it by default? Now that I am going to (temporarily) have multiple computers plugged into the cable modem, do I need to specify routing or NAT rules on the modem itself? I am going to speak to Comcast about this next, but I figured I'd ask here first just so I can get a better grasp on how this type of thing generally plays out.

    Read the article

  • Routing for remote gateway over VPN in Vista/7 broken?

    - by Raymond
    Hi, Situation is as follows. Home computer running Windows 7, sets up VPN connection (LT2P + IPSec, "use remote gateway" disabled) to office. Subnet is 192.168.64.x Office has Draytek Vigor 2920 router, subnet is 192.168.32.x What happens? - VPN connection itself works fine - Can ping any machine on the remote network - When trying to open a webpage from a host in the remote network, the remote server logs the incoming request, but the browser hangs on "waiting for..." and eventually times out. I have observed this problem on Windows Vista and Windows 7. On Windows XP however there is no problem like described above. The only clue I have is that there is a difference in the routing between XP and Vista/7. The output of "route print" on Windows XP looks like this: (See www.latunyi.com/routing_xp.png) So here the gateway for the 192.168.32.x subnet is the IP address that the local computer has in the remote network. The output of "route print" on Windows 7 (and Windows Vista) looks like this: (See www.latunyi.com/routing_win7.png") Now the gateway for the 192.168.32.x subnet is the IP address of the VPN router (32.1). I don't know if that causes this trouble, but it seems a bit strange. Enabling "use default gateway on remote network" doesn't make a difference. Using the new option "Disable class based route addition" in Windows 7 only makes the route to the VPN router disappear. I am really puzzled here. I assume the VPN routing can't be broken in both Vista and Windows 7, and this should just work without manually adding routes. I hope someone has a solution for this problem :-). Thanks!

    Read the article

< Previous Page | 10 11 12 13 14 15 16 17 18 19 20 21  | Next Page >