Interestingly if you come into an assumed view range of a Deathworm a bug, Pune not intended, allows the Deathworm to be seen for a brief second, allowing one to prepare against either attack or attacking the monster.
On Ragnarok I had the 'best' surprise ever and encountered one not knowing what the heck was happening I was gathering meat from killing animals and noticed some dust following me I stayed to see what it was and a giant worm appeared and killed my pteranodon and me along with it
Since everyone else's tips are stupid. If you want to find a deathworm, you can use k mode and look underground. If a worm is nearby, you will see it's body. You can use a land mount like a thyla or a flyer like the wyvern. If flying, point the flyer downwards to make controlling easier. As for fighting it....use whatever dino you have. Rexes are great, wyverns too. Wolves are effective against the worms as well as the alpha to. If you plan to live out on the dunes in SE, be prepared to have random encounters time to time. These worms CAN destroy thatch-stone-adobe. My solution was to just use my rex army but wolves work great early game.
While playing survival, you get yourself a megatherium, head on over to the dunes, start killing yourself some bugs, use the orbital camera to search out a deathworm. It levels you and your mount SUPER fast. Then you can literally hunt down deathworms. By the way, a high level megatherium can kill a rock golem.... hint hint. Vote up so everyone can see!!
Use Sword and a mastercraft shield. Block worm's attack, then attack it twice and put your shield up quickly for worm's next attack. Rinse lather repeat. If you get knocked back too far the sword won't hit. Maintain push towards the worm to stay close while shielding. Practice the timing. When looking for them. Go on foot. They will find you. When u see a dust circle on ground in front, put your shield up for worm's surprise attack and jus keep up the pattern I mentioned. You can it twice after every block. That's how its done on foot.
If you want to het a lot of deathworm horns, go to the northern duines. Use the orbit camera to look underground where they are. Then put some oil jars on the gruind and set them on fire. Get the deathworm into the burning oil and bite him a view times with a high level hunter, like a direwolf. Then run away. If youre in luck, it wont hit you. If it does hit you, dont let it hit you again. If youre just out of the reach of his attac, get your crossbow and set him with flame arrows on fire. Do this a view times. It should die fast. Do this with more deathworms and get yourself some black pearls and deathworm Horns.